I am using Drupal 6, and I have created a custom module which is in the "sites\all\modules\custom" folder; in the same folder there is also the custom.tpl.php file.
I want to place the custom.tpl.php file in the theme folder.
Here is my code:
function custom_menu() {
$items = array();
$items['custom'] = array(
'page callback' => 'custom_page',
'access arguments' => array('access content'),
'type' => MENU_CALLBACK,
);
return $items;
}
function custom_page() {
$result = db_query('SELECT * from node');
return theme('custom', array('output' => $result));
}
function custom_theme() {
return array(
'custom' => array(
'arguments' => array('output' => NULL),
'template' => 'custom',
),
);
}
function template_preprocess_custom(&$variables) {}