Session variables?

Discussion in 'Python' started by Steve, Apr 5, 2004.

  1. Steve

    Steve Guest

    Hi,

    I'm trying to find a clean way of sharing variables across different
    python webpages and scripts and I need something like a session variable
    for each user. Is this possible in Python? I've been "pickling" stuff
    and this doesn't work at all with mutliple users as things get mixed up.
    Is there any clean way of doing this? Thanks,


    Steve
     
    Steve, Apr 5, 2004
    #1
    1. Advertising

  2. Steve

    Paul Rubin Guest

    Steve <nospam@nopes> writes:
    > I'm trying to find a clean way of sharing variables across different
    > python webpages and scripts and I need something like a session
    > variable for each user. Is this possible in Python? I've been
    > "pickling" stuff and this doesn't work at all with mutliple users as
    > things get mixed up. Is there any clean way of doing this? Thanks,


    One way is put all the variables into a browser cookie. You have to
    be careful about security when you do that though. Don't use a pickle.
     
    Paul Rubin, Apr 5, 2004
    #2
    1. Advertising

  3. Steve wrote:
    > Hi,
    >
    > I'm trying to find a clean way of sharing variables across different
    > python webpages and scripts and I need something like a session variable
    > for each user. Is this possible in Python? I've been "pickling" stuff
    > and this doesn't work at all with mutliple users as things get mixed up.
    > Is there any clean way of doing this? Thanks,


    The session module in jonpy package seems to be a nice base for
    sessions, though it lacks some features like explicitly deleting a session.
     
    Tuure Laurinolli, Apr 5, 2004
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Earl Teigrob

    Global Session Variables and Session State

    Earl Teigrob, Dec 16, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    4,292
    Alvin Bruney
    Dec 17, 2003
  2. =?iso-8859-15?Q?Fabr=EDcio_de_Novaes_Kucinskis?=

    Session Variables assigned to the wrong session?

    =?iso-8859-15?Q?Fabr=EDcio_de_Novaes_Kucinskis?=, Jan 20, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    719
    Alvin Bruney [MVP]
    Jan 20, 2005
  3. Robert Faulkner
    Replies:
    0
    Views:
    889
    Robert Faulkner
    Jan 28, 2005
  4. Replies:
    1
    Views:
    950
  5. Replies:
    9
    Views:
    990
Loading...

Share This Page