'$this->' is a self class pointer.
I believe, the only time you should use is it between functions (or variables) of the same class.
Example:
Class students
{
function scoresAverage($numofstudents)
{
$average = $this->calculateTests();
$average = $average / $numofstudents;
return $average;
}
function calculateTests()
{
$scores = $test1 + $test2 + $test3;
return $scores;
}
}
Obviously, this is made up, but I hope you can see the self referancing. Hope that helps. 🙂