<?PHP
class template
{
/*
Simple template class.
Very simple
Artykul.NET
*/
var $Filea;
var $VariableNew;
var $VariableOld;
function chckfile($NameOfFile)
{
if(Is_File($NameOfFile))
{
$this->Filea = $NameOfFile;
return TRUE;
}
else
return false;
}
function AddV($Variab, $NameInFile)
{
$this->VariableNew[] = $Variab;
$this->VariableOld[] = $NameInFile;
}
function Display()
{
$stream = @trim(implode(" ", file($this->Filea)));
$stream = @str_replace($this->VariableOld, $this->VariableNew, $stream);
print $stream;
}
}
?>