You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Tom Miller <mi...@stgabe.org> on 2003/11/14 23:45:09 UTC

Autologin via cookie

I would like to implement a login form with an autologin feature. That 
is, a checkbox which allows the user to save cookies containing their 
username and password. The next time they access the login form, the 
cookies are validated, the login page is bypassed and the first page of 
the site is activated.

I've been attempting to do this with "cycle.activate()" in the 
pageBeginRender() method of the page containing the login form. However, 
when cycle.activate() is invoked, nothing happens.

Actually, something bad happens. The login form comes up instead of 
being bypassed. Then if I type in a valid username and password and hit 
enter: I get this stack trace, indicating, I suppose, that my 
cycle.activate() hosed something up:

org.apache.tapestry.ApplicationRuntimeException
Service direct requires either three or four service context parameters.
Stack Trace:
org.apache.tapestry.engine.DirectService.service(DirectService.java:149)
org.apache.tapestry.engine.AbstractEngine.service(AbstractEngine.java:879)
org.apache.tapestry.ApplicationServlet.doService(ApplicationServlet.java:238) 

org.apache.tapestry.ApplicationServlet.doPost(ApplicationServlet.java:367)
javax.servlet.http.HttpServlet.service(HttpServlet.java:760)

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org