Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save sebastianrothbucher/f775810d9030b1a1c46961f0786c31ed to your computer and use it in GitHub Desktop.
Save sebastianrothbucher/f775810d9030b1a1c46961f0786c31ed to your computer and use it in GitHub Desktop.
Magento (1.9) debug comments for layout
950c950,951
< return $html;
---
> $isNoJsOnly = preg_match('/^\\s*$/', $html) || preg_match('/^\\s*</', $html);
> return $isNoJsOnly ? '<!-- Start ' . $this->getNameInLayout() .' (' . (property_exists($this, '_template') ? ($this->_template . ' ') : '') . '-->' . $html . '<!-- End ' . $this->getNameInLayout() . ' -->' : $html;
one patch
- Block/Abstract.php
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment