What is the best way to access one class from another? What I have is a couple of "core" classes that are loaded into instances at the start of each page. I then load instances of page specific classes. How would I access the already loaded instances of the core classes from inside one of the page specific classes?

I tried a few things that didn't work. Is the only way to do this is to load another instance of the core classes?
I'm finally trying to really get my hands around OOP, which has gone very smooth up until this instance:). I'm using v4 not v5.


I'm looking for something like this:
class Lists {
        function UserList() {
        }
        ...
}
$coreLists = new Lists();
...
class Data {
        function Entry() {
                $users = $coreLists->UserList();  //Accessing Lists Class
                ...
        }
}

Thanks
--
Brent Baisley
Systems Architect
Landover Associates, Inc.
Search & Advisory Services for Advanced Technology Environments
p: 212.759.6400/800.759.0577

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



Reply via email to