Skip to content

Instantly share code, notes, and snippets.

@xymox12
Created February 10, 2014 22:25
Show Gist options
  • Save xymox12/8925508 to your computer and use it in GitHub Desktop.
Save xymox12/8925508 to your computer and use it in GitHub Desktop.
notes to self on template inside wordpress plugin
------------------------------------------------------------
public $pluginPath;
public function include_template_files($template) {
//global $wp;
if (is_tax( 'cp_keywords' )) {
$templatefilename = 'taxonomy-cp_keywords.php';
$template = $this->pluginPath . '/templates/' . $templatefilename;
echo $template;
return $template;
}
return $template;
}
----------------------------------------------------
$CPPublicationCPT->pluginPath = $this->pluginPath;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment