note 26635 added to ref.classobj
| From: | loono at yourwap dot moc | Date: | Thu, 07 Nov 2002 21:06:12 +0000 |
| Subject: | note 26635 added to ref.classobj | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-39100@lists.php.net to get a copy of this message | ||
When using session_register("class") from within a function you first have to declare the
class's variable name as global.
eg:
function CreateClass() {
global $class;
$class = new Class;
$class->setX("5");
session_register("class");
}
--
http://www.php.net/manual/en/ref.classobj.php
http://master.php.net/manage/user-notes.php?action=edit+26635
http://master.php.net/manage/user-notes.php?action=delete+26635
http://master.php.net/manage/user-notes.php?action=reject+26635