Re: Changing address in address bar

2002-01-25 Thread Ted Husted

Another way to go, as MerrilG mentioned, is to define an Action for each
of these locations, and use the mapping's parameter property to pass the
loca=x part. 


 ...
parameter="1"> 


 ...
parameter="2"> 

The displayAvail action can then check the mapping parameter for the
location 

String loca = mapping.getParameter();

If the parameter is null, you can fall back to the original behavior.

This is the same basic idea as setting the parameter to the session, but
puts it all in the action mapping.

A real advantage here is that an implementation detail, like loca=1, is
not being embedded into the view. If this should change for any reason,
you can change the configuration without touching the presentation page.
Also, whatever locations are available for display becomes documented in
the Struts configuration, and so the presentation API now refers to the
locations by name. 

-- Ted Husted, Husted dot Com, Fairport NY USA.
-- Java Web Development with Struts.
-- Tel +1 585 737-3463.
-- Web http://www.husted.com/struts/


Antony Stace wrote:
> 
> Opps, I should have mentioned I have a number of these links on the page, ie I have 
>links on the page to
> 
> http://localhost:8180/testapp/displayAvail.do?loca=1
> http://localhost:8180/testapp/displayAvail.do?loca=2
> http://localhost:8180/testapp/displayAvail.do?loca=3
> http://localhost:8180/testapp/displayAvail.do?loca=4
> 
> and if the user clicks on any of these links they should just get
> 
> http://localhost:8180/testapp/displayAvail.do
> 
> displayed in their browser.
>

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Changing address in address bar

2002-01-24 Thread Antony Stace

No unfortunatly not, they are pulled from a database.

On Fri, 25 Jan 2002 12:37:15 +0530
[EMAIL PROTECTED] wrote:

> are the values of the loc parameter hardcoded?
> in that case you may give different action tags with the same action 
> handler class but with different parameter tag. 
> eg like this.
>  type="org.wxxi.polls.http.Client" 
> name="pollForm"
> scope="request"
> validate="false"
> parameter="input"> 
>  
> 
> 
>  type="org.wxxi.polls.http.Client" 
> name="pollForm"
> scope="request"
> validate="true"
> input="/WEB-INF/Form.jsp"
> parameter="insert">  
>  
> 
> Would look cool in the location bar!!
> Merrill
> 
> 
> 
> 
> 
> 
> Antony Stace <[EMAIL PROTECTED]>
> 01/25/02 10:29 AM
> Please respond to "Struts Users Mailing List"
> 
>  
> To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
> cc: 
> Subject:Re: Changing address in address bar
> 
> 
> Thanks for all the hints guys.  I think I might just live with having 
> those extra parts in the 
> address bar.
> 
> Cheers
> 
> Tony
> 
> 
> On Fri, 25 Jan 2002 15:52:26 +1100
> <[EMAIL PROTECTED]> wrote:
> 
> > The only thing I can suggest is to do it in javascript:
> > 
> > 
> > function setVar(var) {
> >switch(var)
> >case 1:
> ><% 
> javax.servlet.http.HttpSession session =
> > request.getSession();
> > session.setAttribute("key","value1");
> >%>
> >break;
> >case 2:
> ><% 
> javax.servlet.http.HttpSession session =
> > request.getSession();
> > session.setAttribute("key","value2");
> >%>
> >break;
> >case 3:
> ><% 
> javax.servlet.http.HttpSession session =
> > request.getSession();
> > session.setAttribute("key","value3");
> >%>
> >break;
> >default:
> ><% 
> javax.servlet.http.HttpSession session =
> > request.getSession();
> > session.setAttribute("key","value4");
> >%>
> >break;
> > }
> > 
> > 
> > and have an onClick() method handler in the URL:
> > http://localhost:8180/testapp/displayAvail.do";
> > onClick="setVar(1);">Link
> > http://localhost:8180/testapp/displayAvail.do";
> > onClick="setVar(2);">Link
> > http://localhost:8180/testapp/displayAvail.do";
> > onClick="setVar(3);">Link
> > http://localhost:8180/testapp/displayAvail.do";
> > onClick="setVar(4);">Link
> > 
> > Or similar
> > 
> > -Original Message-
> > From: Antony Stace [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, 25 January 2002 15:36
> > To: Struts Users Mailing List
> > Subject: Re: Changing address in address bar
> > 
> > 
> > Opps, I should have mentioned I have a number of these links on the
> > page, ie I have links on the page to
> > 
> > http://localhost:8180/testapp/displayAvail.do?loca=1
> > http://localhost:8180/testapp/displayAvail.do?loca=2
> > http://localhost:8180/testapp/displayAvail.do?loca=3
> > http://localhost:8180/testapp/displayAvail.do?loca=4
> > 
> > and if the user clicks on any of these links they should just get
> > 
> > http://localhost:8180/testapp/displayAvail.do
> > 
> > displayed in their browser.
> > 
> > 
> > 
> > On Fri, 25 Jan 2002 15:30:56 +1100
> > <[EMAIL PROTECTED]> wrote:
> > 
> > > okay...
> > > 
> > > in the page/servlet that has the link, put it in the session there...
> > > if in js

Re: Changing address in address bar

2002-01-24 Thread MerrilG

are the values of the loc parameter hardcoded?
in that case you may give different action tags with the same action 
handler class but with different parameter tag. 
eg like this.

name="pollForm"
scope="request"
validate="false"
parameter="input"> 
 



name="pollForm"
scope="request"
validate="true"
input="/WEB-INF/Form.jsp"
parameter="insert">  
 

Would look cool in the location bar!!
Merrill






Antony Stace <[EMAIL PROTECTED]>
01/25/02 10:29 AM
Please respond to "Struts Users Mailing List"

 
    To:     "Struts Users Mailing List" <[EMAIL PROTECTED]>
cc: 
Subject:Re: Changing address in address bar


Thanks for all the hints guys.  I think I might just live with having 
those extra parts in the 
address bar.

Cheers

Tony


On Fri, 25 Jan 2002 15:52:26 +1100
<[EMAIL PROTECTED]> wrote:

> The only thing I can suggest is to do it in javascript:
> 
> 
> function setVar(var) {
>switch(var)
>case 1:
><% 
javax.servlet.http.HttpSession session =
> request.getSession();
> session.setAttribute("key","value1");
>%>
>break;
>case 2:
><% 
javax.servlet.http.HttpSession session =
> request.getSession();
> session.setAttribute("key","value2");
>%>
>break;
>case 3:
><% 
javax.servlet.http.HttpSession session =
> request.getSession();
> session.setAttribute("key","value3");
>%>
>break;
>default:
><% 
javax.servlet.http.HttpSession session =
> request.getSession();
> session.setAttribute("key","value4");
>%>
>break;
> }
> 
> 
> and have an onClick() method handler in the URL:
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(1);">Link
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(2);">Link
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(3);">Link
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(4);">Link
> 
> Or similar
> 
> -Original Message-
> From: Antony Stace [mailto:[EMAIL PROTECTED]]
> Sent: Friday, 25 January 2002 15:36
> To: Struts Users Mailing List
> Subject: Re: Changing address in address bar
> 
> 
> Opps, I should have mentioned I have a number of these links on the
> page, ie I have links on the page to
> 
> http://localhost:8180/testapp/displayAvail.do?loca=1
> http://localhost:8180/testapp/displayAvail.do?loca=2
> http://localhost:8180/testapp/displayAvail.do?loca=3
> http://localhost:8180/testapp/displayAvail.do?loca=4
> 
> and if the user clicks on any of these links they should just get
> 
> http://localhost:8180/testapp/displayAvail.do
> 
> displayed in their browser.
> 
> 
> 
> On Fri, 25 Jan 2002 15:30:56 +1100
> <[EMAIL PROTECTED]> wrote:
> 
> > okay...
> > 
> > in the page/servlet that has the link, put it in the session there...
> > if in jsp: 
> > <% 
> > javax.servlet.http.HttpSession session = request.getSession();
> > session.setAttribute("key","value");
> > %>
> > 
> > in servlet:
> > see prvious method...
> > 
> > -Original Message-
> > From: Antony Stace [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, 25 January 2002 15:26
> > To: Struts Users Mailing List
> > Subject: Re: Changing address in address bar
> > 
> > 
> > Thanks for the reply.  This still leaves the address bar with the 
> > 
> > ?loca=3-(1)
> > 
> > part.  I want to get rid of (1)
> > 
> > Any ideas?
> > 
> > On Fri, 25 Jan 2002 15:24:28 +1100
> > <[EMAIL PROTECTED]> wrote:
> > 
> > > Set the loca=3 into the 

Re: Changing address in address bar

2002-01-24 Thread Antony Stace

Thanks for all the hints guys.  I think I might just live with having those extra 
parts in the 
address bar.

Cheers

Tony


On Fri, 25 Jan 2002 15:52:26 +1100
<[EMAIL PROTECTED]> wrote:

> The only thing I can suggest is to do it in javascript:
> 
> 
> function setVar(var) {
>   switch(var)
>   case 1:
>   <% javax.servlet.http.HttpSession session =
> request.getSession();
>   session.setAttribute("key","value1");
>   %>
>   break;
>   case 2:
>   <% javax.servlet.http.HttpSession session =
> request.getSession();
>   session.setAttribute("key","value2");
>   %>
>   break;
>   case 3:
>   <% javax.servlet.http.HttpSession session =
> request.getSession();
>   session.setAttribute("key","value3");
>   %>
>   break;
>   default:
>   <% javax.servlet.http.HttpSession session =
> request.getSession();
>   session.setAttribute("key","value4");
>   %>
>   break;
> }
> 
> 
> and have an onClick() method handler in the URL:
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(1);">Link
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(2);">Link
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(3);">Link
> http://localhost:8180/testapp/displayAvail.do";
> onClick="setVar(4);">Link
> 
> Or similar
> 
> -Original Message-
> From: Antony Stace [mailto:[EMAIL PROTECTED]]
> Sent: Friday, 25 January 2002 15:36
> To: Struts Users Mailing List
> Subject: Re: Changing address in address bar
> 
> 
> Opps, I should have mentioned I have a number of these links on the
> page, ie I have links on the page to
> 
> http://localhost:8180/testapp/displayAvail.do?loca=1
> http://localhost:8180/testapp/displayAvail.do?loca=2
> http://localhost:8180/testapp/displayAvail.do?loca=3
> http://localhost:8180/testapp/displayAvail.do?loca=4
> 
> and if the user clicks on any of these links they should just get
> 
> http://localhost:8180/testapp/displayAvail.do
> 
> displayed in their browser.
> 
> 
> 
> On Fri, 25 Jan 2002 15:30:56 +1100
> <[EMAIL PROTECTED]> wrote:
> 
> > okay...
> > 
> > in the page/servlet that has the link, put it in the session there...
> > if in jsp: 
> > <% 
> > javax.servlet.http.HttpSession session = request.getSession();
> > session.setAttribute("key","value");
> > %>
> > 
> > in servlet:
> > see prvious method...
> > 
> > -Original Message-
> > From: Antony Stace [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, 25 January 2002 15:26
> > To: Struts Users Mailing List
> > Subject: Re: Changing address in address bar
> > 
> > 
> > Thanks for the reply.  This still leaves the address bar with the 
> > 
> > ?loca=3-(1)
> > 
> > part.  I want to get rid of (1)
> > 
> > Any ideas?
> > 
> > On Fri, 25 Jan 2002 15:24:28 +1100
> > <[EMAIL PROTECTED]> wrote:
> > 
> > > Set the loca=3 into the HttpSession.
> > > 
> > > 
> > > javax.servlet.http.*;
> > > HttpSession session = request.getSession();
> > > ...
> > > // set into session..
> > > session.setAttribute("key","value");
> > > 
> > > // get from session...
> > > String loca = session.getAttribute("key");
> > > 
> > > HTH...
> > > 
> > > -Original Message-
> > > From: Antony Stace [mailto:[EMAIL PROTECTED]]
> > > Sent: Friday, 25 January 2002 14:53
> > > To: [EMAIL PROTECTED]
> > > Subject: Changing address in address bar
> > > 
> > > 
> > > Hi
> > > 
> > > I have a link in a page
> > > 
> > > 
> > > http://localhost:8180/testapp/displayAvail.do?loca=3
> > > 
> > > which a user can click on.  When the page is diplayed I do not want
> > the 
> > > 
> > > ?loca=3
> > > 
> > 

Re: Changing address in address bar

2002-01-24 Thread Arron Bates

Only way that it can be done without being seen as a querystring, is via 
a form's POST method. But realistically would have to be activated via 
JavaScript to do what you want. It also means that if the user clicks 
their browser's "back" button to go back to the page, you'll get the 
typical question dialog "this page was generated from POST data, do you 
want to post it again?"... yes, page loads, no, IE page expired output 
or equivalent. Less friendlier to the user than a name/value in their 
address bar.

...Or...
...you can hide the current document in a frame, but that's not "passe" 
with most developers (personally I just think they're misunderstood :).

Arron.


Antony Stace wrote:

>Opps, I should have mentioned I have a number of these links on the page, ie I have 
>links on the page to
>
>http://localhost:8180/testapp/displayAvail.do?loca=1
>http://localhost:8180/testapp/displayAvail.do?loca=2
>http://localhost:8180/testapp/displayAvail.do?loca=3
>http://localhost:8180/testapp/displayAvail.do?loca=4
>
>and if the user clicks on any of these links they should just get
>
>http://localhost:8180/testapp/displayAvail.do
>
>displayed in their browser.
>
>
>
>On Fri, 25 Jan 2002 15:30:56 +1100
><[EMAIL PROTECTED]> wrote:
>
>>okay...
>>
>>in the page/servlet that has the link, put it in the session there...
>>if in jsp: 
>><% 
>>javax.servlet.http.HttpSession session = request.getSession();
>>session.setAttribute("key","value");
>>%>
>>
>>in servlet:
>>see prvious method...
>>
>>-Original Message-
>>From: Antony Stace [mailto:[EMAIL PROTECTED]]
>>Sent: Friday, 25 January 2002 15:26
>>To: Struts Users Mailing List
>>Subject: Re: Changing address in address bar
>>
>>
>>Thanks for the reply.  This still leaves the address bar with the 
>>
>>?loca=3-(1)
>>
>>part.  I want to get rid of (1)
>>
>>Any ideas?
>>
>>On Fri, 25 Jan 2002 15:24:28 +1100
>><[EMAIL PROTECTED]> wrote:
>>
>>>Set the loca=3 into the HttpSession.
>>>
>>>
>>>javax.servlet.http.*;
>>>HttpSession session = request.getSession();
>>>...
>>>// set into session..
>>>session.setAttribute("key","value");
>>>
>>>// get from session...
>>>String loca = session.getAttribute("key");
>>>
>>>HTH...
>>>
>>>-Original Message-
>>>From: Antony Stace [mailto:[EMAIL PROTECTED]]
>>>Sent: Friday, 25 January 2002 14:53
>>>To: [EMAIL PROTECTED]
>>>Subject: Changing address in address bar
>>>
>>>
>>>Hi
>>>
>>>I have a link in a page
>>>
>>>
>>>http://localhost:8180/testapp/displayAvail.do?loca=3
>>>
>>>which a user can click on.  When the page is diplayed I do not want
>>>
>>the 
>>
>>>?loca=3
>>>
>>>part displayed in the link location on the address bar, ie I just want
>>>
>>>http://localhost:8180/testapp/displayAvail.do
>>>
>>>displayed in the address bar.   Is there anyway using struts that I
>>>
>>can
>>
>>>do this?
>>>
>>>-- 
>>>
>>>
>>>Cheers
>>>
>>>Tony
>>>-
>>>
>>>
>>>
>>>_
>>>
>>>Do You Yahoo!?
>>>
>>>Get your free @yahoo.com address at http://mail.yahoo.com
>>>
>>>
>>>
>>>
>>>--
>>>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]>
>>
>>
>>-- 
>>
>>
>>Cheers
>>
>>Tony
>>-
>>
>>
>>
>>_
>>
>>Do You Yahoo!?
>>
>>Get your free @yahoo.com address at http://mail.yahoo.com
>>
>>
>>
>>
>>--
>>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]>
>>
>
>



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>




RE: Changing address in address bar

2002-01-24 Thread matthewr

The only thing I can suggest is to do it in javascript:


function setVar(var) {
switch(var)
case 1:
<% javax.servlet.http.HttpSession session =
request.getSession();
session.setAttribute("key","value1");
%>
break;
case 2:
<% javax.servlet.http.HttpSession session =
request.getSession();
session.setAttribute("key","value2");
%>
break;
case 3:
<% javax.servlet.http.HttpSession session =
request.getSession();
session.setAttribute("key","value3");
%>
break;
default:
<% javax.servlet.http.HttpSession session =
request.getSession();
session.setAttribute("key","value4");
%>
break;
}


and have an onClick() method handler in the URL:
http://localhost:8180/testapp/displayAvail.do";
onClick="setVar(1);">Link
http://localhost:8180/testapp/displayAvail.do";
onClick="setVar(2);">Link
http://localhost:8180/testapp/displayAvail.do";
onClick="setVar(3);">Link
http://localhost:8180/testapp/displayAvail.do";
onClick="setVar(4);">Link

Or similar

-----Original Message-
From: Antony Stace [mailto:[EMAIL PROTECTED]]
Sent: Friday, 25 January 2002 15:36
To: Struts Users Mailing List
Subject: Re: Changing address in address bar


Opps, I should have mentioned I have a number of these links on the
page, ie I have links on the page to

http://localhost:8180/testapp/displayAvail.do?loca=1
http://localhost:8180/testapp/displayAvail.do?loca=2
http://localhost:8180/testapp/displayAvail.do?loca=3
http://localhost:8180/testapp/displayAvail.do?loca=4

and if the user clicks on any of these links they should just get

http://localhost:8180/testapp/displayAvail.do

displayed in their browser.



On Fri, 25 Jan 2002 15:30:56 +1100
<[EMAIL PROTECTED]> wrote:

> okay...
> 
> in the page/servlet that has the link, put it in the session there...
> if in jsp: 
> <% 
> javax.servlet.http.HttpSession session = request.getSession();
> session.setAttribute("key","value");
> %>
> 
> in servlet:
> see prvious method...
> 
> -Original Message-
> From: Antony Stace [mailto:[EMAIL PROTECTED]]
> Sent: Friday, 25 January 2002 15:26
> To: Struts Users Mailing List
> Subject: Re: Changing address in address bar
> 
> 
> Thanks for the reply.  This still leaves the address bar with the 
> 
> ?loca=3-(1)
> 
> part.  I want to get rid of (1)
> 
> Any ideas?
> 
> On Fri, 25 Jan 2002 15:24:28 +1100
> <[EMAIL PROTECTED]> wrote:
> 
> > Set the loca=3 into the HttpSession.
> > 
> > 
> > javax.servlet.http.*;
> > HttpSession session = request.getSession();
> > ...
> > // set into session..
> > session.setAttribute("key","value");
> > 
> > // get from session...
> > String loca = session.getAttribute("key");
> > 
> > HTH...
> > 
> > -Original Message-
> > From: Antony Stace [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, 25 January 2002 14:53
> > To: [EMAIL PROTECTED]
> > Subject: Changing address in address bar
> > 
> > 
> > Hi
> > 
> > I have a link in a page
> > 
> > 
> > http://localhost:8180/testapp/displayAvail.do?loca=3
> > 
> > which a user can click on.  When the page is diplayed I do not want
> the 
> > 
> > ?loca=3
> > 
> > part displayed in the link location on the address bar, ie I just
want
> > 
> > http://localhost:8180/testapp/displayAvail.do
> > 
> > displayed in the address bar.   Is there anyway using struts that I
> can
> > do this?
> > 
> > -- 
> > 
> > 
> > Cheers
> > 
> > Tony
> >
-
> > 
> > 
> > 
> > _
> > 
> > Do You Yahoo!?
> > 
> > Get your free @yahoo.com address at http://mail.yahoo.com
> > 
> > 
> > 
> > 
> > --
> > To unsubscribe, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
> > <mailto:[EMAIL PROTECTED]>
> > 
> > 
> > --
> > To unsubscribe, e-mail:
> <mailto:[EMAIL 

Re: Changing address in address bar

2002-01-24 Thread Antony Stace

Opps, I should have mentioned I have a number of these links on the page, ie I have 
links on the page to

http://localhost:8180/testapp/displayAvail.do?loca=1
http://localhost:8180/testapp/displayAvail.do?loca=2
http://localhost:8180/testapp/displayAvail.do?loca=3
http://localhost:8180/testapp/displayAvail.do?loca=4

and if the user clicks on any of these links they should just get

http://localhost:8180/testapp/displayAvail.do

displayed in their browser.



On Fri, 25 Jan 2002 15:30:56 +1100
<[EMAIL PROTECTED]> wrote:

> okay...
> 
> in the page/servlet that has the link, put it in the session there...
> if in jsp: 
> <% 
> javax.servlet.http.HttpSession session = request.getSession();
> session.setAttribute("key","value");
> %>
> 
> in servlet:
> see prvious method...
> 
> -Original Message-
> From: Antony Stace [mailto:[EMAIL PROTECTED]]
> Sent: Friday, 25 January 2002 15:26
> To: Struts Users Mailing List
> Subject: Re: Changing address in address bar
> 
> 
> Thanks for the reply.  This still leaves the address bar with the 
> 
> ?loca=3-(1)
> 
> part.  I want to get rid of (1)
> 
> Any ideas?
> 
> On Fri, 25 Jan 2002 15:24:28 +1100
> <[EMAIL PROTECTED]> wrote:
> 
> > Set the loca=3 into the HttpSession.
> > 
> > 
> > javax.servlet.http.*;
> > HttpSession session = request.getSession();
> > ...
> > // set into session..
> > session.setAttribute("key","value");
> > 
> > // get from session...
> > String loca = session.getAttribute("key");
> > 
> > HTH...
> > 
> > -Original Message-
> > From: Antony Stace [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, 25 January 2002 14:53
> > To: [EMAIL PROTECTED]
> > Subject: Changing address in address bar
> > 
> > 
> > Hi
> > 
> > I have a link in a page
> > 
> > 
> > http://localhost:8180/testapp/displayAvail.do?loca=3
> > 
> > which a user can click on.  When the page is diplayed I do not want
> the 
> > 
> > ?loca=3
> > 
> > part displayed in the link location on the address bar, ie I just want
> > 
> > http://localhost:8180/testapp/displayAvail.do
> > 
> > displayed in the address bar.   Is there anyway using struts that I
> can
> > do this?
> > 
> > -- 
> > 
> > 
> > Cheers
> > 
> > Tony
> > -
> > 
> > 
> > 
> > _
> > 
> > Do You Yahoo!?
> > 
> > Get your free @yahoo.com address at http://mail.yahoo.com
> > 
> > 
> > 
> > 
> > --
> > 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]>
> 
> 
> -- 
> 
> 
> Cheers
> 
> Tony
> -
> 
> 
> 
> _
> 
> Do You Yahoo!?
> 
> Get your free @yahoo.com address at http://mail.yahoo.com
> 
> 
> 
> 
> --
> 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]>


-- 


Cheers

Tony
-


_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>




RE: Changing address in address bar

2002-01-24 Thread matthewr

okay...

in the page/servlet that has the link, put it in the session there...
if in jsp: 
<% 
javax.servlet.http.HttpSession session = request.getSession();
session.setAttribute("key","value");
%>

in servlet:
see prvious method...

-Original Message-
From: Antony Stace [mailto:[EMAIL PROTECTED]]
Sent: Friday, 25 January 2002 15:26
To: Struts Users Mailing List
Subject: Re: Changing address in address bar


Thanks for the reply.  This still leaves the address bar with the 

?loca=3-(1)

part.  I want to get rid of (1)

Any ideas?

On Fri, 25 Jan 2002 15:24:28 +1100
<[EMAIL PROTECTED]> wrote:

> Set the loca=3 into the HttpSession.
> 
> 
> javax.servlet.http.*;
> HttpSession session = request.getSession();
> ...
> // set into session..
> session.setAttribute("key","value");
> 
> // get from session...
> String loca = session.getAttribute("key");
> 
> HTH...
> 
> -Original Message-
> From: Antony Stace [mailto:[EMAIL PROTECTED]]
> Sent: Friday, 25 January 2002 14:53
> To: [EMAIL PROTECTED]
> Subject: Changing address in address bar
> 
> 
> Hi
> 
> I have a link in a page
> 
> 
> http://localhost:8180/testapp/displayAvail.do?loca=3
> 
> which a user can click on.  When the page is diplayed I do not want
the 
> 
> ?loca=3
> 
> part displayed in the link location on the address bar, ie I just want
> 
> http://localhost:8180/testapp/displayAvail.do
> 
> displayed in the address bar.   Is there anyway using struts that I
can
> do this?
> 
> -- 
> 
> 
> Cheers
> 
> Tony
> -
> 
> 
> 
> _
> 
> Do You Yahoo!?
> 
> Get your free @yahoo.com address at http://mail.yahoo.com
> 
> 
> 
> 
> --
> 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]>


-- 


Cheers

Tony
-



_

Do You Yahoo!?

Get your free @yahoo.com address at http://mail.yahoo.com




--
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]>




Re: Changing address in address bar

2002-01-24 Thread Antony Stace

Thanks for the reply.  This still leaves the address bar with the 

?loca=3-(1)

part.  I want to get rid of (1)

Any ideas?

On Fri, 25 Jan 2002 15:24:28 +1100
<[EMAIL PROTECTED]> wrote:

> Set the loca=3 into the HttpSession.
> 
> 
> javax.servlet.http.*;
> HttpSession session = request.getSession();
> ...
> // set into session..
> session.setAttribute("key","value");
> 
> // get from session...
> String loca = session.getAttribute("key");
> 
> HTH...
> 
> -Original Message-
> From: Antony Stace [mailto:[EMAIL PROTECTED]]
> Sent: Friday, 25 January 2002 14:53
> To: [EMAIL PROTECTED]
> Subject: Changing address in address bar
> 
> 
> Hi
> 
> I have a link in a page
> 
> 
> http://localhost:8180/testapp/displayAvail.do?loca=3
> 
> which a user can click on.  When the page is diplayed I do not want the 
> 
> ?loca=3
> 
> part displayed in the link location on the address bar, ie I just want
> 
> http://localhost:8180/testapp/displayAvail.do
> 
> displayed in the address bar.   Is there anyway using struts that I can
> do this?
> 
> -- 
> 
> 
> Cheers
> 
> Tony
> -
> 
> 
> 
> _
> 
> Do You Yahoo!?
> 
> Get your free @yahoo.com address at http://mail.yahoo.com
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:
> 
> For additional commands, e-mail:
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 


-- 


Cheers

Tony
-


_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




RE: Changing address in address bar

2002-01-24 Thread matthewr

Set the loca=3 into the HttpSession.


javax.servlet.http.*;
HttpSession session = request.getSession();
...
// set into session..
session.setAttribute("key","value");

// get from session...
String loca = session.getAttribute("key");

HTH...

-Original Message-
From: Antony Stace [mailto:[EMAIL PROTECTED]]
Sent: Friday, 25 January 2002 14:53
To: [EMAIL PROTECTED]
Subject: Changing address in address bar


Hi

I have a link in a page


http://localhost:8180/testapp/displayAvail.do?loca=3

which a user can click on.  When the page is diplayed I do not want the 

?loca=3

part displayed in the link location on the address bar, ie I just want

http://localhost:8180/testapp/displayAvail.do

displayed in the address bar.   Is there anyway using struts that I can
do this?

-- 


Cheers

Tony
-



_

Do You Yahoo!?

Get your free @yahoo.com address at http://mail.yahoo.com




--
To unsubscribe, e-mail:

For additional commands, e-mail:



--
To unsubscribe, e-mail:   
For additional commands, e-mail: