By jeffabailey on
I simply want to allow the output of a function to pick up a theme template within a module. The code below is what I have and I want web_hosting_article_directory.tpl.php to be picked up and used much like any other themeable function. I assume I am just missing something from the existing documentation but cannot find it for the life of me.
function article_menu($may_cache) {
$items = array();
$items[] = array(
'path' => 'web-hosting-article-directory',
'callback' => 'web_hosting_article_directory',
'type' => MENU_CALLBACK,
'access' => TRUE,
);
return $items;
}
function web_hosting_article_directory() {
return theme('web_hosting_article_directory');
}
function theme_web_hosting_article_directory() {
$output = '';
return $output;
}
Comments
_phptemplate_callback
see http://api.drupal.org/api/function/_phptemplate_callback/5
thanks
works like a charm