I want to pass the value from module to page tpl file in drupal.I have created a custom module 'one_time_popup'.I have created a sample soutput and tried to pass it and print in page.tpl.php after footer section.but doesn't shows any thing.What I did wrong.I'm a newbie
function one_time_popup_menu(){
$items['oneTimePopupData'] = array(
'title' => 'One time Popup',
'page callback' => 'one_time_popup_user_login',
'type' => MENU_CALLBACK,
'access callback' => TRUE,
);
return $items;
}
function one_time_popup_user_login(&$edit, $account){
...
$output='value from one time popup module!';
return theme('photo_order',array('results' => $output));
}
function one_time_popup_theme() {
return array(
'photo_order' => array(
'template' => 'page',
'variables' => array(
'results' => NULL,
),
),
);
}
Tpl file(page.tpl)
<?php echo $results; ?>