Created
December 7, 2011 18:39
-
-
Save billerickson/1444031 to your computer and use it in GitHub Desktop.
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
<?php | |
/** | |
* Code Template | |
* Use archive-code.php template for any taxonomy archives in 'code-tag' taxonomy | |
* | |
* @param string, default template path | |
* @return string, modified template path | |
*/ | |
function be_code_template( $template ){ | |
if( is_tax( 'code-tag' ) ) | |
$template = get_query_template( 'archive-code' ); | |
return $template; | |
} | |
add_filter( 'template_include', 'be_code_template' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment