Drupal theme function is not called?
I am trying to create a theme function that create a little iframe for my videos. I am calling the function in my menu callback function. The problem is that the theme function is not called. I tried to append the module name at the beginning of the theme function and also removed and it didn't help. I clear the cache every time I make changes and enabled the backtrace in my devel module and I see the following warning:
warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'mymodule_mobile_mymodue_mobile_build_iframe' not found or invalid function name in call_user_func_array() (line 656 of /var/www/includes/theme.inc). =>
function my_callback_function(){
$output = theme('mymodule_mobile_build_iframe',array(
'arg1'=> $stream,
'arg2'=> $node->nid,)
);
return $output
}
function mymodule_mobile_theme(){
return array(
'mymodule_mobile_build_iframe' => array(
'arguments' => array(
'arg1' => NULL,
'arg2' => NULL,),),);
}
function theme_mymodule_mobile_build_iframe($arg1,$arg2){
$host = 'http://www.myhost.com';
$output = '<video width="320" height="240" controls="controls"> <source src=
"'.$host.'/'.$arg1.'/'.$arg2.'/playlist.m3u8" type="video/mp4" />
Your browser does not support the video tag.
</video>';
return $output;
}
Thank you all in advance!