Page 1 of 1
ACCESS CLASSES
Posted: Thu Oct 24, 2002 9:41 am
by kendall
hey,
quick review here
i want to fid out if i can assign variables to a class from within a function that is not in the class?
and can i access a class attribute in a function ?
what about globalizing the class so as to access it from page to page and include pages?
Kendall
Re: ACCESS CLASSES
Posted: Thu Oct 24, 2002 10:40 am
by BDKR
Before going off in a direction in particular, can I ask what you're trying to do?
Cheers,
BDKR
Posted: Thu Oct 24, 2002 12:34 pm
by rev
Kendall,
To be perfectly blunt here, I suggest reading a bit more about classes and how they are to be used.
http://www.php.net/manual/en/language.oop.php
Posted: Thu Oct 24, 2002 12:42 pm
by volka
that are at least three topics each worth a whole tutorial (certainly there are already some) to cover it in general.
I pick the one that is least general
what about globalizing the class so as to access it from page to page and include pages?
making data available throughout several requests(/pages) is no matter of globalizing. There are several ways to do this and one of them is session support that was added to php 4.
serializing objects(/classes) is described at
http://www.php.net/manual/en/language.oop.serialization.php