Re: Getting static member for a class which name is stored

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Greg Beaver wrote:

How about:

<?php
class Myclass
{
    public static $myvar = "easy enough";
}

echo Myclass::$myvar;
?>

The only problem is if you want to be able to generically access a static variable from any class that has it, like $Myclass::$myvar.

Greg


Hi Greg,

Yup, Exactly

That is the problem we are attempting to deal with :)
(hence the name of this thread)


Best Regards Jake Press

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


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux