0

This question already has an answer here:

I have a issue related to owl slider I make a slider into phtml file slider.php And call into default.xml file.but the problem it is not take a slider to homepage.. Thanks

marked as duplicate by Abdul, Khoa TruongDinh, Raphael at Digital Pianism, 7ochem, Murtuza Zabuawala Jan 2 '17 at 12:36

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • What you have passed in your default.xml file ? – Manthan Dave Jan 2 '17 at 10:39
  • I want in block then what am i doing? – Moin Malek Jan 2 '17 at 11:06
0

IF you want that in your block , Then call your slider block name and your template name to homepage cms block.

Try below code :

{{block class="VendorName\Modulename\Block\Blockname" template="Vendorname_ModuleName::your_template_file.phtml"}}

You can find your homepage block from admin ->content->Blocks->Homepage Block . Edit it and call your block by written above code.

  • Hello Manthan..!! create a one block and in that call images then in phtml file call js and css for the slider..is is proper? – Moin Malek Jan 2 '17 at 11:23
  • @MoinMalek yes call your css in layout file and js in requirejs-config.js and pass it to your template file . it will works – Manthan Dave Jan 2 '17 at 11:24
  • You can create a widget to be used in different area and you can configure it through backoffice. – Franck Garnier Jan 2 '17 at 11:30
  • can u send a structure – Moin Malek Jan 2 '17 at 11:31

Not the answer you're looking for? Browse other questions tagged or ask your own question.