Discussion:
Hiding URL Parameters
Ramadoss Chinnakuzhandai
2004-03-04 19:31:46 UTC
Permalink
Is there anyway I can hide sending all the URL parameters (in the browser address) from once page to other whenever I do submit/click on html link?

any help would be appreciated.

Tnx in advance,

-Ramadoss
Qureshi, Affan
2004-03-04 19:35:27 UTC
Permalink
Only if you submit the form using a POST method instead of the default GET. If you want to achieve such functionality on the click of a link, you may need some Javascript support to do a POST in the background on the 'click' event of the hyperlink.

./Affan

-----Original Message-----
From: Ramadoss Chinnakuzhandai [mailto:***@register.com]
Sent: Thursday, March 04, 2004 1:32 PM
To: struts-***@jakarta.apache.org
Subject: Hiding URL Parameters



Is there anyway I can hide sending all the URL parameters (in the browser address) from once page to other whenever I do submit/click on html link?

any help would be appreciated.

Tnx in advance,

-Ramadoss


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-***@jakarta.apache.org
For additional commands, e-mail: struts-user-***@jakarta.apache.org
Slattery, Tim - BLS
2004-03-04 19:35:31 UTC
Permalink
> Is there anyway I can hide sending all the URL parameters (in
> the browser address) from once page to other whenever I do
> submit/click on html link?

If you set method="post" in your "form" element (which Strut's
<html:form...> tag does as default) the arguments will not appear as part of
the URL. But if you're using an html hyperlink, or the Struts <html:link...>
tag, you cannot pass arguments without having them appear in the URL.

--
Tim Slattery
***@bls.gov
Ramadoss Chinnakuzhandai
2004-03-04 19:40:36 UTC
Permalink
>>But if you're using an html hyperlink, or the Struts <html:link...>
>>tag, you cannot pass arguments without having them appear in the URL.

Im using <html:link> in most cases.....and there is the need of hiding URL parameters despite I'm using method="post" in my <html:form>

any clue??

-Ramadoss

-----Original Message-----
From: Slattery, Tim - BLS [mailto:***@bls.gov]
Sent: Thursday, March 04, 2004 2:36 PM
To: 'Struts Users Mailing List'
Subject: RE: Hiding URL Parameters


> Is there anyway I can hide sending all the URL parameters (in
> the browser address) from once page to other whenever I do
> submit/click on html link?

If you set method="post" in your "form" element (which Strut's
<html:form...> tag does as default) the arguments will not appear as part of
the URL. But if you're using an html hyperlink, or the Struts <html:link...>
tag, you cannot pass arguments without having them appear in the URL.

--
Tim Slattery
***@bls.gov


---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-***@jakarta.apache.org
For additional commands, e-mail: struts-user-***@jakarta.apache.org
Slattery, Tim - BLS
2004-03-04 19:45:26 UTC
Permalink
> >>But if you're using an html hyperlink, or the Struts <html:link...>
> >>tag, you cannot pass arguments without having them appear
> in the URL.
>
> Im using <html:link> in most cases.....and there is the need
> of hiding URL parameters despite I'm using method="post" in
> my <html:form>

> any clue??

I already said it. A link is a GET request. With a GET, the parameters are
part of the request. There's no way around that.

--
Tim Slattery
***@bls.gov
Michael McGrady
2004-03-04 22:41:24 UTC
Permalink
Well, yes and no. There are lots of things to be done, actually. First,
whatever is sent to the server as a "get" can be disguised. You are not
locked into anything except some agreement between client and server. You
can use Diffie-Hellman if you want, for example. Second, what you can do
depends in great part on what your application is doing. Why don't you use
some JavaScript, however, to convert your link to an html form?

At 11:45 AM 3/4/2004, you wrote:
> > >>But if you're using an html hyperlink, or the Struts <html:link...>
> > >>tag, you cannot pass arguments without having them appear
> > in the URL.
> >
> > Im using <html:link> in most cases.....and there is the need
> > of hiding URL parameters despite I'm using method="post" in
> > my <html:form>
>
> > any clue??
>
>I already said it. A link is a GET request. With a GET, the parameters are
>part of the request. There's no way around that.
>
>--
>Tim Slattery
>***@bls.gov
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: struts-user-***@jakarta.apache.org
>For additional commands, e-mail: struts-user-***@jakarta.apache.org
Wendy Smoak
2004-03-04 20:02:29 UTC
Permalink
> Im using <html:link> in most cases.....and there is the need
> of hiding URL parameters despite I'm using method="post" in
> my <html:form>
> any clue??

A bit of onclick JavaScript to set the form fields to the values you
need, and then submit the form with a POST. Not to hide the attributes,
but I do that with several links on my pages, and it works fine.

--
Wendy Smoak
Application Systems Analyst, Sr.
ASU IA Information Resources Management
Ramadoss Chinnakuzhandai
2004-03-05 00:19:54 UTC
Permalink
tnx all for your help....sure I would try that way.

-Ramadoss


-----Original Message-----
From: Michael McGrady [mailto:***@michaelmcgrady.com]
Sent: Thu 3/4/2004 5:41 PM
To: Struts Users Mailing List
Cc:
Subject: RE: Hiding URL Parameters



Well, yes and no. There are lots of things to be done, actually. First,
whatever is sent to the server as a "get" can be disguised. You are not
locked into anything except some agreement between client and server. You
can use Diffie-Hellman if you want, for example. Second, what you can do
depends in great part on what your application is doing. Why don't you use
some JavaScript, however, to convert your link to an html form?

At 11:45 AM 3/4/2004, you wrote:
> > >>But if you're using an html hyperlink, or the Struts <html:link...>
> > >>tag, you cannot pass arguments without having them appear
> > in the URL.
> >
> > Im using <html:link> in most cases.....and there is the need
> > of hiding URL parameters despite I'm using method="post" in
> > my <html:form>
>
> > any clue??
>
>I already said it. A link is a GET request. With a GET, the parameters are
>part of the request. There's no way around that.
>
>--
>Tim Slattery
>***@bls.gov
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: struts-user-***@jakarta.apache.org
>For additional commands, e-mail: struts-user-***@jakarta.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-***@jakarta.apache.org
For additional commands, e-mail: struts-user-***@jakarta.apache.org
Loading...