Kevin you got it!
Wow.. that gave many of us pain.. however I thought about that and said
to myself that would just start a new session.. anyways that didnt.
For the rest of the people looking at this e-mail, you may look at the
code, its updated.
Thanks.
Josepablo P�rez
> You must understand that although it's all the same script each frame
is its
> own HTML page and Session vars will not be called into a frame unless
you
> specify it. So..
>
> if ($QUERY_STRING == "2.html")
> {
> session_start(); // call session vars into this frame.
> // .. blah blah blah..
> }
>
> Also set your variables before you register them into the session.
If you
> don't have register globals on it won't work the other way around.
Hope
> this helps. Very clever by the way I never thought of doing it this
way.
> I'd always called the PHP into the SRC tag. :-)
>
> Good luck
> -Kevin
>
>
>
> ----- Original Message -----
> From: <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Wednesday, July 03, 2002 11:33 AM
> Subject: Re: [PHP] Re: SESSION newbie question ***STILL UNRESOLVED***
>
>
> > I did as you said Richard, however I still encounter the same
problem,
> > you can take a look at the code in test.txt, I updated it too.
> >
> >
> > For other people, here is the original message:
> >
> > Hello,
> >
> > I got this example of sessions: www.net.co.cr/test/test.php ,
> > however, as you can see in the code at /test/text.txt , isnt
$_SESSION
> > ['tree'] suppose to contain a value and not be NULL?
> >
> > Thanks.
> >
> >
> > > > >www.net.co.cr/test/test.php
> > > >
> > > > <?
> > > > if ($QUERY_STRING == "")
> > > > {
> > > > session_start();
> > > > $_SESSION['tree'] = "green";
> > > >
> > > >
> > > >
> > > > Change the line above to these two lines:
> > > > session_register('tree');
> > > > $tree = 'green';
> > > >
> > > > Think of $_SESSION (and the other $_XXX vars) as "read-only"
> > > >
> > > > Use session_register() to say which variables should "live long
and
> > > prosper"
> > > > and then just use them like regular variables.
> > > >
> > > >
> > > > echo '<HTML>
> > > > <HEAD>
> > > > <TITLE>frame session test</TITLE>
> > > > </HEAD>
> > > >
> > > > <FRAMESET cols="165,*" border=0 frameborder=0 framespacing=0">
> > > > <FRAME SRC="?1.html" name="mainMenu" MARGINWIDTH="0"
> > > MARGINHEIGHT="0"
> > > > border=0 frameborder=0 FRAMESPACING="0" NORESIZE SCROLLING="no">
> > > > <FRAME SRC="?2.html" name="right" MARGINWIDTH="0" WIDTH="0"
> > > border=0
> > > > frameborder=0 FRAMESPACING="0">
> > > >
> > > > </FRAMESET>
> > > >
> > > > </HTML>'; }
> > > >
> > > > if ($QUERY_STRING == "1.html")
> > > > { echo "<b>This is just a dummy frame.</b>"; }
> > > >
> > > > if ($QUERY_STRING == "2.html")
> > > > {
> > > > echo "<b>";
> > > > echo "The value of \$_SESSION['tree'] is:";
> > > > echo gettype($_SESSION['tree']);
> > > > echo "</b>";
> > > > }
> > > >
> > > > ?>
> > > >
> > > >
> > > > --
> > > > Like Music? http://l-i-e.com/artists.htm
> > > >
> > > >
> > > > --
> > > > PHP General Mailing List (http://www.php.net/)
> > > > To unsubscribe, visit: http://www.php.net/unsub.php
> > > >
> > > >
> > >
> > >
> > >
> > >
> > >
> >
> >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php