Last active
December 23, 2015 05:18
-
-
Save zenman/6585624 to your computer and use it in GitHub Desktop.
Add a bar at the bottom of the page that shows the template being used. Simply add to your functions.php file and comment out when done with it.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Add a bar at the bottom of the page that shows the template being used. | |
*/ | |
function show_template() { | |
global $template; | |
$style = ' | |
background-color:rgba(0,0,0,1); | |
position:fixed; | |
bottom:0; | |
right:0; | |
left:0; | |
color:#fff; | |
opacity:.2; | |
padding:.5em; | |
font-size:.6em; | |
'; | |
echo '<div style="'.$style.'">'.$template.'</div>'; | |
} | |
add_action('wp_footer', 'show_template'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment