To this : session_register('somevar') and it'll work..
if your're using PHP4, you can also do this : $_SESSIONS['somevar']=$somevar

Regards,
P.E. Baroiller

"Paul" <[EMAIL PROTECTED]> a écrit dans le message de news:
002601c28743$42bebbf0$[EMAIL PROTECTED]
>
> I have a simple object/class:
>
> Class MainData {
> Var items =array();
>
> ...some other functions but nothing to initialize it
> }
>
> in a code when I do :
>
> $somevar= new MainData();
> session_register($somevar);
>
> I get "notice" type of error:
> Notice: Object to string conversion in C...\page_vip.php on line 27
>
> How can I avoid this? It does not stop code and it is not a fatal error
> but perhaps I am missing something
>
> Paul
>
>



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

Reply via email to