Right. SharedObject is going to be the only way to do this.  The
problem is you cannot use the standard J2EE HttpSession object to
store the session state because it is transient surviving only the
like of the browser executable.  You will need to persist this state
off to some less transient storage like a database.  When the user
logs back in, you would read some opaque value (read GUID for
instance) out of the SharedObject, then lookup the users state in the
database and then store it into the transient HttpSession.  Any
changes to the session you will also have to manually persist off to
the database (there are eventing hooks on the HttpSession so you could
automate this).

The user will need to log back in after a browser shutdown, but you
could recover all state.  Actually BTW this is a good way to handle
lots of login/session business rules which arent easily supported via
J2EE.

-- 
Dave Wolf
Cynergy Systems, Inc.
Adobe Flex Alliance Partner
http://www.cynergysystems.com
http://www.cynergysystems.com/blogs

Email:  [EMAIL PROTECTED]
Office: 866-CYNERGY



--- In flexcoders@yahoogroups.com, "Stacy Young" <[EMAIL PROTECTED]> wrote:
>
> Once all browser instances are closed you're pretty much stuck. (as
with other web technologies)
> 
>  
> 
> Without a session identifier to match up with on the server, there's
no way to access that session data. You *could* store session data in
a local shared object (flash cookie) and have your application read
from that on startup to determine whether or not the user needs to be
brought to a login page. Then when the user explicitly logs off you
can nuke that shared object. Not the most secure approach though.
> 
>  
> 
> Cheers,
> 
> Stace
> 
>  
> 
> ________________________________
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]
On Behalf Of Daniel
> Sent: Sunday, September 10, 2006 4:26 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Handling Login
> 
>  
> 
> Im trying to create a Login screen where I can save a user's session
> information, so I can retrieve that later and use it for some
validations.
> Is there a way that I can save this info as a session that last even
> when the user closes the browser, and until he signs out?
> 
> How would you recommend it should be handled? I'd love to see some
> examples if you have any.
> 
> Thanks in advance!
> 
>  
> 
>  
> 
> -- 
> WARNING
> -------
> This electronic message and its attachments may contain
confidential, proprietary or legally privileged information, which is
solely for the use of the intended recipient.  No privilege or other
rights are waived by any unintended transmission or unauthorized
retransmission of this message.  If you are not the intended recipient
of this message, or if you have received it in error, you should
immediately stop reading this message and delete it and all
attachments from your system.  The reading, distribution, copying or
other use of this message or its attachments by unintended recipients
is unauthorized and may be unlawful.  If you have received this e-mail
in error, please notify the sender.
> 
> AVIS IMPORTANT
> --------------
> Ce message électronique et ses pièces jointes peuvent contenir des
renseignements confidentiels, exclusifs ou légalement privilégiés
destinés au seul usage du destinataire visé.  L'expéditeur original ne
renonce à aucun privilège ou à aucun autre droit si le présent message
a été transmis involontairement ou s'il est retransmis sans son
autorisation.  Si vous n'êtes pas le destinataire visé du présent
message ou si vous l'avez reçu par erreur, veuillez cesser
immédiatement de le lire et le supprimer, ainsi que toutes ses pièces
jointes, de votre système.  La lecture, la distribution, la copie ou
tout autre usage du présent message ou de ses pièces jointes par des
personnes autres que le destinataire visé ne sont pas autorisés et
pourraient être illégaux.  Si vous avez reçu ce courrier électronique
par erreur, veuillez en aviser l'expéditeur.
>







--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/flexcoders/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[EMAIL PROTECTED] 
    mailto:[EMAIL PROTECTED]

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to