Hi. To use echo $Navigation->getHeader(); and echo $Navigation->getFooter(); perhaps try the following.
At the top of search_function.php add:
PHP Code:
ob_start();
require("/path/to/header.php");
$my_header_file = ob_get_contents();
ob_end_clean();
ob_start();
require("/path/to/footer.php");
$my_footer_file = ob_get_contents();
ob_end_clean();
and then in search_function.php replace:
PHP Code:
$t_mstrings = compact('powered_by_link','title_message','phpdig_version','result_message','nav_bar','ignore_message','ignore_commess','pages_bar','previous_link','next_link','templates_links');
with the following:
PHP Code:
$t_mstrings = compact('my_header_file','my_footer_file','powered_by_link','title_message','phpdig_version','result_message','nav_bar','ignore_message','ignore_commess','pages_bar','previous_link','next_link','templates_links');
Make the header.php and footer.php files contain echo $Navigation->getHeader(); and echo $Navigation->getFooter(); respectively, and then use <phpdig:my_header_file/> and <phpdig:my_footer_file/> in the template.
Remember to remove any "word" wrapping in the above code.