Skip to content

Instantly share code, notes, and snippets.

@veirus
Last active October 31, 2017 08:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save veirus/ec6584ead93b8dc219b0325b7771fcdd to your computer and use it in GitHub Desktop.
Save veirus/ec6584ead93b8dc219b0325b7771fcdd to your computer and use it in GitHub Desktop.
Show template file name to figure out what fucking part is now loaded into view
<?php if (1): ?>
<h1 class="title title-debug" style="position: fixed; bottom:20px; right: 0; margin: 16px 0; padding: 10px; border-radius: 8px 0 0 8px; font-size: 16px; background-color: #d4e0c1; opacity: .42; z-index: 9999; user-select: none; text-shadow: 1px 1px 0px green, 1px 2px 3px rgba(0,255,0,.3), 3px 3px 3px hsla(173, 67%,47%,.75), -1px -1px 0px red, -3px -3px 3px rgba(255,0,0,.3);">
<!-- debug -->
<?php global $template; echo basename($template); ?>
</h1>
<?php endif; ?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment