I try to override listing.phtml for the purpose of remove add to cart button from widget. I follow this link

But no effects will be happen.I am using customize theme which extends to magento blank. The details are

Default template path:


Customize template path to override default template:


In customize templates I am just remove one div tag(class="product details").

I am wondering why its not get reflect.

Thanks in advance.

  • Did you run magento cache:clear? – user37304 Mar 14 '16 at 18:52
  • Yes, I remove var folder as well as clear cache via admin – Bilal Usean Mar 14 '16 at 18:56
  • I can try from terminal also but no effect( bin/magento cache:clean) – Bilal Usean Mar 14 '16 at 19:00

If you turn on template hints is it using the template you think it is to render that listing?

Store > Configuration > Advanced > Debug > Enabled Template Path Hints for Storefront > Yes

| improve this answer | |
  • 1
    awesome idea to check.its my fault actual path is "/var/www/html/magento2/app/design/frontend/ChennaiBox/Style/Magento_Catalog/templates/product/widget/new/content/new_grid.phtml". – Bilal Usean Mar 14 '16 at 19:22

Magento2 does not refresh content if files are residing in pub/static and coming from cached content. Please make sure to delete pub/static files and also running content deploy process once. This might solve your issue. You may delete below files from the project,

Delete var/view_preprocessed, pub/static/frontend/theme/theme, var/cache/ , var/page_cache/, var/generation/ and then run below command,

php bin/magento setup:static-content:deploy

This should work.


| improve this answer | |

Go to developer mode and back to production:

php bin/magento deploy:mode:set developer

php bin/magento deploy:mode:set production

then Magento will apply Your changes

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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