I am asking a slightly different question (which has been asked before). I want to direct a user to a page that is passed on to him, via an email, say.
http://somewhere.com/somecomp/servlet/somecomp/SOME.vm,id?1 I would imagine that this link is passed on as a parameter and read by a .class file, then passon to Velocity via context.put("somelink", "the_above_link"); then, read by the Login.vm file using: <form method="post" action="$link.setAction("Login").setPage($the_above_link)"> 1. I don't know which .java file I should use to read the link. 2. in the file that reads this link, what should be put in place of the XXXX String link = data.getParameters().getString("XXXX"); 3. setAction("Login").setPage($YYY) in the Form field does not seem to work, $YYY is not accepted, a String (i.e. Somefile.vm) is OK. thanks michael > On Tue, 7 Jan 2003 14:44, you wrote: >> Hello, >> >> I've also been looking at this post and want to have users with >> different Roles be directed to different Screens after they log in. >> >> What I don't get about this post his how all the parameters that he's >> placing in the Login.vm form are going to be related to the user in >> the MyLoginUser action when the server processes the login request. >> >> What I've tried is using data.getACL() and then using the >> AccessControlList's hasRole() method in my MyLoginUser class, but >> getACL() returns null in the LoginUser class so that didn't get me too >> far. > > You can use the ACL in your Login action, but only after you have > properly logged in the user. We use the following code in our Login > action before redirecting them to the appropriate homepage: > ------------ > User user = TurbineSecurity > .getAuthenticatedUser( username, password ); > data.setUser(user); > data.setACL(TurbineSecurity.getACL(user)); > user.setHasLoggedIn(new Boolean(true)); > user.updateLastLogin(); > TurbineSecurity.saveUser(user); > data.save(); > ------------ > >> The below post has the quote "It is not possible to do a redirect >> after login. TDK 2.1 does not permit this yet." Is this true? I'm >> using 2.1, has this been fixed in 2.2? > > This should work fine in 2.1. > > Regards, > > -- Rodney > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> For additional > commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
