When I run code in my custom module similar to the code below I get a white screen... I don't seem to be getting any errors in my log (probably due to my server configuration). Long story short callback_function will pass the argument from the url to another_function, which will check a database table for a value. Can someone please tell me where my error is? Im clearly missing something.
function hook_menu() {
$items = array();
$items['mymodule/%'] = array(
'title' => 'Test',
'description' => 'Pass argument from url into callback function to process',
'page callback' => 'callback_function',
'page arguments' => array(1),
'access arguments' => array('access content'),
'type' => MENU_NORMAL_ITEM,
);
return $items;
}
function callback_function($argument){
another_function($argument);
}
function another_function($argument){
return($argument);
}
It seems as though your "callback_function" is not returning data from your "another_function".
Is this a typo?