0

I am using a third-party theme called Porto.

It has a slider on the main screen, and I can't figure out which files are used in displaying it. Turning on backend template hints doesn't help located it. In fact, template hints show that it doesn't have a template of it's own. There are a few items on my homepage for which this is true.

I have searched the root directory via Visual Studio Code (my IDE) for every class and ID related this slider, and I still cannot find it. I have been trying for hours to figure out where this slider is being called from. Ideally, I would like to find out where in the XML it is being called, so that I can remove it and place something else in its place.

As a side note, why is it so terribly difficult to understand what is causing what in Magento, and isn't this painful for most developers?

enter image description here

2
  • You can try this: github.com/AOEpeople/Aoe_TemplateHints shouldgive you somemor hints.
    – sv3n
    Commented May 17, 2018 at 16:42
  • Hi @sv3n, is this only for Magento 1 - I see it has a "skin" folder? I am using Magento 2.
    – AdamJSim
    Commented May 17, 2018 at 17:04

2 Answers 2

2

Have you searched around for any mentions of "banner-slider"? Peeking at the Porto M2 theme demo now, and it looks like Owl Carousel gets added to whatever banner-slider id is there -- might point you in the right direction.

4
  • Unfortunately this does not work. I see a lot of XML files in app\code. I hesitate to make changes there, because I believe I should be in app\design when making front-end changes. Also, even when I delete these various "demo".xml pages, and flush cache, I fail to see any changes.
    – AdamJSim
    Commented May 17, 2018 at 17:06
  • If I were in your shoes, I'd probably create a custom theme that inherits the Porto theme and then make your overrides there. Then you'd probably need to create a cms_index_index.xml file and remove the slider block from there. Hmm. Man, if this wasn't a premium theme I'd download it and take a look for ou!
    – brackfost
    Commented May 17, 2018 at 17:19
  • Thank you for spending the time to help. I have created a child theme already and am working off of it, as I do not want to mess around with the actual porto theme. I cannot find where the slider is being generated. I was really hoping for an XML file that calls a template. I have found that structure in other places on the site. It's fairly straight-forward. As for this, I am at a complete loss.
    – AdamJSim
    Commented May 17, 2018 at 17:32
  • Any chance you could toss everything on github or something?
    – brackfost
    Commented May 17, 2018 at 17:37
0

For this you need to follow the following steps.

1) Login To Admin

2) Navigate to System->Configuration.

3) change Current Configuration Scope to your website.

4) Navigate to Advanced->Developer which is available at the lower side of the page.

5) Under debug set Template Path Hints = yes and Add Block Names to Hints = yes and refresh the page to which you want to debug you will get a path for the phtml file and block file.

6) to find a block for ex Mage_Page_Block_Switch you need to move for the location app\code\core\Mage\Page\Block\Switch.php where Mage is the namespace / company name, Page is the module name and Switch is the block file name.

Hope this will help you.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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