On 20 Aug 2003 09:57:20 -0500, you wrote:

>I've seen this a few times in some code examples...
>
>XXX::XXX
>
>What do the 2 colons signify?

Static method of an object.

Calling a method of a class without first instantiating an instance of the
class.

        /* Class A has method B */
        class A {
                function B ($s = "None") {
                        echo ("<p> input : $s</p>");
                }
        }

        /* $C is an instance of A */
        $C = new A ();

        /* invoke A::B */
        A::B ('call 1');

        /* invoke $C->B */
        $C->B ('call 2');


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to