using the object-oriented approach, i'm trying to call a public function in a function in the same class, but it throws an error: Call to undefined function h()
php:
class Name {
. .. .
public function h($s)
{
echo htmlspecialchars($s, ENT_QUOTES);
}
public function formatQuotes($row)
{
return "<p id=\"ab_quotes\">" . h($row['cQuotes']) . "</p>"
. "<p id=\"ab_author\">" . h($row['vAuthor']) . "</p>";
}
}
what am i missing here?