Session strategies for liveCode server

2012-01-14 Thread Malte Brill
Hi all (and especially those using server) I would like to create a little web based thing using server that will require a login on some of the pages and would really like to have sessions there (until the browser closes, or the user logs out). What would be the best way to handle this? Cookie

Re: Session strategies for liveCode server

2012-01-14 Thread Pierre Sahores
Hi Malte, Encoded data inside cookies + SQL stored sessions works well there. This two parts design is more secure than cookies or hidden without any SQL part in the process. Best, Le 14 janv. 2012 à 23:02, Malte Brill a écrit : > Hi all (and especially those using server) > > I would like

Re: Session strategies for liveCode server

2012-01-14 Thread Mark Schonewille
Hi Malte, I use PHP, where you can define a session with session_start() and save info in the $_SESSION variable. PHP's session feature is really awesome (but I don't think regular PHP programmer realise how awesome it really is). I would expect Rev Server to have exactly the same feature. If n

Re: Session strategies for liveCode server

2012-01-14 Thread stephen barncard
You can find some use of pw/user schemes in the examples below http://splash21.on-rev.com/- complete CMS written in Livecode http://www.troz.net/onrev/ - Sarah - code for cookies and other goodies http://revigniter.com/ - Ralf Bitter's CMS On 14 January 2012 14:02, Malte Bril

Re: Session strategies for liveCode server

2012-01-14 Thread stephen barncard
Session Variables are available in the latest version of Livecode Server. (5) On 14 January 2012 14:12, Pierre Sahores wrote: > Hi Malte, > > Encoded data inside cookies + SQL stored sessions works well there. This > two parts design is more secure than cookies or hidden without any SQL part >

Re: Session strategies for liveCode server

2012-01-14 Thread Andre Garzia
Current LiveCode server has sessions just like PHP, actually I think they modeled it after PHP session. The most usual path is to store a unique id in a cookie and use this id to point to a session on disk or database. On Sat, Jan 14, 2012 at 8:18 PM, stephen barncard wrote: > Session Variables

Re: Session strategies for liveCode server

2012-01-14 Thread Alex Tweedly
The example from splash21 works well for login/registration, etc. - but it was written for revserver pre-5.0, so he does his own cookie / local data to simulate sessions. Easier, if you can, to use the session support in 5.0 - but note that on-rev (at least on loki) does not yet support 5.0. (I

Re: Session strategies for liveCode server

2012-01-14 Thread -=>JB<=-
I registered and tried to download but could never get it to verify my account when I would try to login. -=>JB<=- On Jan 14, 2012, at 4:10 PM, Alex Tweedly wrote: > The example from splash21 works well for login/registration, etc. - but it > was written for revserver pre-5.0, so he does his o

Re: Session strategies for liveCode server

2012-01-14 Thread -=>JB<=-
After checking my email I see a email to activate the account and it works now. -=>JB<=- On Jan 14, 2012, at 4:10 PM, Alex Tweedly wrote: > The example from splash21 works well for login/registration, etc. - but it > was written for revserver pre-5.0, so he does his own cookie / local data to

Re: Session strategies for liveCode server

2012-01-14 Thread Björnke von Gierke
where is this session cookie handling documented? On 15.01.2012, at 01:51, -=>JB<=- wrote: > After checking my email I see a email to activate > the account and it works now. > > -=>JB<=- > > > > On Jan 14, 2012, at 4:10 PM, Alex Tweedly wrote: > >> The example from splash21 works well for

Re: Session strategies for liveCode server

2012-01-14 Thread stephen barncard
In the notes that come with the 5.0 version. But you combined the two concepts. $_SESSION is an server global array in ram, not a cookie. sqb 2012/1/14 Björnke von Gierke > where is this session cookie handling documented? > > > On 15.01.2012, at 01:51, -=>JB<=- wrote: > > > After checking my

Re: Session strategies for liveCode server

2012-01-14 Thread Andre Garzia
BvG, http://www.runrev.com/downloads/livecode/5_0_0/How_do_I_use_Sessions_on_LiveCode_Server.pdf =) 2012/1/14 Björnke von Gierke : > where is this session cookie handling documented? > > > On 15.01.2012, at 01:51, -=>JB<=- wrote: > >> After checking my email I see a email to activate >> the acco

Re: Session strategies for liveCode server

2012-01-14 Thread Björnke von Gierke
I'm on on-rev. so for me there's no place to go for documentation at all, and altho there is a pdf that contains most stuff, it's usually out of date, unattainable or gets otherwise forgotten by RunRev. i'll mail them when i ever really need this, but i wish they'd put more effort on quality ove

Re: Session strategies for liveCode server

2012-01-15 Thread Martin Koob
to the On-rev Server or updates to the on-rev editor etc. I have tried to post a few things and respond to posts when I can but not many people use the forum. -- View this message in context: http://runtime-revolution.278305.n4.nabble.com/Session-strategies-for-liveCode-server

Re: Session strategies for liveCode server

2012-01-15 Thread Mark Wieder
Martin- Sunday, January 15, 2012, 5:45:19 AM, you wrote: > It would be helpful if RunRev staff would post updates there about things > such as version changes to the On-rev Server or updates to the on-rev editor > etc. I have tried to post a few things and respond to posts when I can but > not

Re: Session strategies for liveCode server

2012-01-16 Thread Malte Brill
Thank you all for the feedback. This is on a LAN and I will be able to use the 5.x engine there, so it seems $_session will be my friend. Will need to put a little work into it. Alex, facebook authentication sounds interesting, however, will not be something I can do for this project. for others

Re: Session strategies for liveCode server

2012-01-19 Thread Malte Brill
Anyone, pretty please? Andre, Stephen? I just do not get it. I have a login form now and that one calls a liveCode script to validate the user and start a session: start" else include "login.html" end if end if ?> As soon as I click the start link the session ap

Re: Session strategies for liveCode server

2012-01-19 Thread Michael Kann
- On Thu, 1/19/12, Malte Brill wrote: From: Malte Brill Subject: Re: Session strategies for liveCode server To: use-livecode@lists.runrev.com Date: Thursday, January 19, 2012, 9:02 AM Anyone, pretty please? Andre, Stephen? I just do not get it. I have a login form now and that one calls a l

Re: Session strategies for liveCode server

2012-01-19 Thread Michael Kann
Malte, Here's the working code for php, if that helps. Notice that session_start() comes before anything else, including WORKING CODE: --- On Thu, 1/19/12, Malte Brill wrote: From: Malte Brill Subject: Re: Session strategies for liv

Re: Session strategies for liveCode server

2012-01-19 Thread Malte Brill
Michael, thanks for getting back! I am afraid I do not have it working yet. :-( I now tried this: And always get a session counter of 1. Maybe I must solve this differently. :-( Cheers, Malte ___ use-livecode mailing list use-livecode@lists.run

Re: Session strategies for liveCode server

2012-01-19 Thread Malte Brill
Thanks to sturgis from the forums I got it working now. The missing link was that the session needs to be stopped before the script terminates. This is a working example: Happy camper now. :-) Cheers, Malte ___ use-livecode mailing list use-livecod