Take a look at this demo they have posted:

http://www.thomasfrank.se/sessvarsTestPage1.html


Specifically, this:


setName=function(f){
        sessvars.username=f.elements[0].value;
        document.getElementById('enterYourName').style.display="none";
        alert('Welcome to this test of sessvars.js, '+sessvars.username+'!');
        location.href="sessvarsTestPage2.html"
};


Notice they are declaring a brand new sessvar object called sessvar.username


You can add new objects at anytime.


Be sure you call in sessvars.js BEFORE prototype.

Like...

  <script type="text/javascript" src="sessvars.js"></script>
  <script type="text/javascript" src="prototype.js"></script>

In the  <head>


Rick



On Mon, Jun 22, 2009 at 4:06 AM, Brendan O Connor <brenda...@gmail.com>wrote:

> Thank you very much
>
> when you create your session object you use the follwing   sessvars.myObj =
> {var1:"", var2:"0",}
>
> Can you add variables to this object at a later stage or do you have to
> declare all you varaibles at this stage.
>
>
>
>
>
>
>
> 2009/6/19 Rick Waldron <waldron.r...@gmail.com>
>
> Since no one else has replied, justly so as this is not a Prototype related
>> question...
>>
>> I'm vaguely familiar with sessvars.js - what did you need help with?
>>
>> Rick
>>
>>
>>
>> On Fri, Jun 19, 2009 at 10:47 AM, cob <brenda...@gmail.com> wrote:
>>
>>>
>>> Has anyone here used the sessvars lib, would like to ask a question if
>>> you have
>>>
>>> thx
>>> Boc
>>>
>>>
>>
>>
>>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to