Newb Warning : question on functions and variables
Posted: Mon Jun 21, 2004 5:02 pm
I need to re-write a function, but I can't find anything on basic PHP that explains this (i've never had to use itbefore so I dont know what to call it)
So the code above, what does $this-> mean?
I've seen variables set up as $blah = "value"; but what does the "->" signify?
And links to online resources that explain this would be helpful
feyd|please use
Code: Select all
function load_file($filename, $sName)
{
$nName = "";
$template_path = $this->templates_root . "/" . $filename;
if (file_exists($template_path))
{
$this->DBlocks[$sName] = join('',file($template_path));
$nName = $this->NextDBlockName($sName);
while($nName != "")
{
$this->SetBlock($sName, $nName);
$nName = $this->NextDBlockName($sName);
}
}
}I've seen variables set up as $blah = "value"; but what does the "->" signify?
And links to online resources that explain this would be helpful
feyd|please use
Code: Select all
tags for posting code.[/color]