Replicating the PHP include function
Posted: Thu Sep 23, 2010 3:22 am
I am trying to do,
But it doesn't print the contents of the page that was included.
Code: Select all
$localPath = getcwd().'\\';
function fileInclude($file, $required = false)
{
if($required == true)
{return require($localPath.$file);}
else
{return include($localPath.$file);}
}