Turn template path hints off from command line
-
16-10-2019 - |
문제
For whatever reason, I just did a mysqldump of our magento database, imported it into a new database, and suddenly template path hints are on, how can I turn these off from the command line? Or what table/column do I need to change in the database to turn these off?
Thank you!
해결책
You can turn them off by running the following query:
UPDATE core_config_data SET value = '0' WHERE path LIKE '%template_hints%';
After running the query make sure you clean the var/cache directory too when you are in the Magento root. (rm -rf var/cache/*
)
Enjoy ;)
다른 팁
alternative is using phpStorm IDE with magicento plugin, it has very usefull tools for magento development, turn on/off path hints, clean cache is also there.
Switch some properties to true ;
class Mage_Core_Block_Template extends Mage_Core_Block_Abstract
{
...
//near the row 66-67
protected static $_showTemplateHints = true;
protected static $_showTemplateHintsBlocks = true;
...
}
If out use n98-magerun2 script from https://github.com/netz98/n98-magerun2
Run the following from website root to enable hints
n98-magerun2.phar dev:template-hints enable
And this to disable
n98-magerun2.phar dev:template-hints disable
In 2.2 you can run the command line:
php bin/magento dev:template-hints:enable
php bin/magento dev:template-hints:disable