Susalito project questions

3 views
Skip to first unread message

Milos Zikic

unread,
Nov 16, 2011, 10:25:40 AM11/16/11
to sausali...@googlegroups.com
Hello,

My name is Milos and I am an ETH student. I am currently working on some project using Susalito and I have many problems.

I will start with an easiest one and it is about cookies.

If I say cookie:create-session(<user>$a</user>) and immediately after that I build a page for displaying that cookie (without interaction with the client), it will or it will not be shown? 

In other words, does client need to send a new request for a page in order for cookie to be transferred.

William Candillon

unread,
Nov 16, 2011, 10:47:30 AM11/16/11
to sausali...@googlegroups.com
Hello,

Yes, the cookie needs to be returned to the client and to be send
again in the next request.
One solution is to store the session data into a collection node with
and id and just use the cookie for passing around this id.
The following module is an example of sessions managed server side:
https://gist.github.com/1370411

Does this help?

Kind regards,

William

Milos Zikic

unread,
Nov 17, 2011, 12:29:39 PM11/17/11
to Sausalito Users
William thank you very much for your help.

I've solved problem in a similar way, and I've found where was the
problem before.

Now everything works :)

Cheers

William Candillon

unread,
Nov 17, 2011, 12:30:54 PM11/17/11
to sausali...@googlegroups.com
This is so cool!

Good luck with your project & happy coding!

Kind regards,

William

Reply all
Reply to author
Forward
0 new messages