> Scenario 2,
>
> User types http://host/app/protectedCommand.m?p1=v1&p2=v2&p3=v3
>
> Same idea, user is redirected to login and then if login is successfull
they
> should be redirected through to initially selected command, only this time
> there are a number of URL paramters that I wish to have set, Does anyone
> have a simple way of acheiving this functionality.

David,

I dont know if you find it simple or elegant. My feeling is that it is not.
Anywhay
this is what I do:

in authentication-form.jsp I populate hidden fields into login form like
this:

 <c:forEach items="${paramValues}" var="paramValue">
  <c:forEach items="${paramValue.value}" var="v">
   <c:if test="${paramValue.key != 'loginName' && paramValue.key !=
'loginPassword'}">
    <input type="hidden" name="<c:out value="${paramValue.key}"/>"
value="<c:out value="${v}"/>"/>
   </c:if>
  </c:forEach>
 </c:forEach>

This code filters out loginName and loginPassword since they are defined as
an
ordinary input fields.

I have this working with registration too. Ie. the user may happen to our
site, submit a
search form (not being logged in yet), find out that registration is needed,
register, and
then get search results. It really is necessary to remember these get or
post parameters
especially if session expires and user has filled in an input form and does
not want to
retype everything again.

with best wishes,
Taavi



-------------------------------------------------------
This SF.Net email sponsored by: Free pre-built ASP.NET sites including
Data Reports, E-commerce, Portals, and Forums are available now.
Download today and enter to win an XBOX or Visual Studio .NET.
http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01
[INVALID FOOTER]

Reply via email to