I did a Google search on getcwd() and found a posting which gave an alternative function to get the current directory: dirname(__FILE__);
So I inserted the folllowing line in easymod_display_functions.php to fix $template_file so that it has a full path instead of starting with "." for the current directory.
Code: Select all
function display_template( $template_file, $variables)
{
// fix $template_file (which is in format "./templates/<filename>.php
// so that it has the full path
$template_file = dirname(__FILE__) . substr($template_file, 1, 999);
if (!file_exists( $template_file))
// make sure the tpl file exists
{
echo "<h1><span class="ok">A required file [$template_file] is missing. Aborting install.</span></h1>\n" ;
}
Stuart