Re: [PHP-PEAR] Error Messages and Scope Resolution
[email protected] ("Paul Meagher")
| Newsgroups | php.pear |
|---|---|
| Message-ID | <014201c09612$4c120140$6c35de18@datavore> |
Error Messages and Scope ResolutionUsing the :: scope resolution operator, you can access class methods without using the new operator to declare an instance.
This works:
<?php
class test {
function printError() {
print "This is an error";
}
}
test::printError();
?>
Don't know if that helps.
Regards,
Paul Meagher
----- Original Message -----
From: Robert Kelly
To: '[email protected]'
Sent: Tuesday, February 13, 2001 4:35 PM
Subject: [PHP-PEAR] Error Messages and Scope Resolution
My forehead's a bit bloody from beating up against this.
How does the scope resolution operator (::) function within PHP?
I am trying to implement PEAR_Error just like the DB.php does
and I am failing miserably. I can't find any RTFM on php.net or google,
I see C++ stuff, but it doesn't explain what is required to occur.
Any help would be excellent. Thanks!
-Bob Kelly
[email protected]