unwanted varables in GET string..

  • Thread starter Graham Mattingley
  • Start date
G

Graham Mattingley

Hello Group,

I have a small problem I dont seem to be able to fix.

When I have a form which sends data using GET to an ASP page, it addes X & Y
into the get string URL

see below

http://www.test.co.uk/JOBS1/people/resort_search.asp?resort_id=41&I1.x=9&I1.
y=12

the bit I dont want it &I1.x=9&I1.y=12

I1 is the name of the image I use as the send button, and the x & y seems to
be where I click on the image, but it just makes my URLs looks messy and
confusing.

Has anybody else had this problem, how do I fix it

Cheers

Graham Mattingley
 
A

Adrienne

Hello Group,

I have a small problem I dont seem to be able to fix.

When I have a form which sends data using GET to an ASP page, it addes
X & Y into the get string URL

see below

http://www.test.co.uk/JOBS1/people/resort_search.asp?resort_id=41&I1.x=9
&I1. y=12

the bit I dont want it &I1.x=9&I1.y=12

I1 is the name of the image I use as the send button, and the x & y
seems to be where I click on the image, but it just makes my URLs looks
messy and confusing.

Has anybody else had this problem, how do I fix it

Cheers

Graham Mattingley

There is no way around that. That kind of form control always sends the x
& y coordinates. If you don't want the x & y coordinates, use a regular
submit button, or use the post method instead of get.
 
B

Bob Barrows

Graham said:
Hello Group,

I have a small problem I dont seem to be able to fix.

When I have a form which sends data using GET to an ASP page, it
addes X & Y into the get string URL

see below

http://www.test.co.uk/JOBS1/people/resort_search.asp?resort_id=41&I1.x=9&I1.
y=12

the bit I dont want it &I1.x=9&I1.y=12

I1 is the name of the image I use as the send button, and the x & y
seems to be where I click on the image, but it just makes my URLs
looks messy and confusing.
Why not clear the name property of the image element? If it needs to be
referred to in client-side code, you can use its id property. As you're
discovering, all named elements are included in the GET.

Bob Barrows
 
D

Dave Anderson

Graham Mattingley said:
When I have a form which sends data using GET to an ASP page, it
addes X & Y into the get string URL...

...the bit I dont want it &I1.x=9&I1.y=12...

...I1 is the name of the image I use as the send button, and the
x & y seems to be where I click on the image, but it just makes
my URLs looks messy and confusing.

1. Who cares about the URL? When you go to the following URL, does it affect
your browsing experience when additional session-specific data is added to
the end?

http://www.amazon.com/exec/obidos/tg/detail/-/1591098149


2. If you really must eliminate the x & y, stop using <INPUT TYPE="image">.
You can accomplish the same functionality in this manner:

<A HREF="" ONCLICK="document.myForm.submit();return false">
<IMG BORDER="0" ...></A>

FWIW, zeroing the BORDER attribute isn't necessary in IE, but some other
browsers will insert a border unless you do. And NN4 does not recognize
ONCLICK for IMG -- hence the anchor tags.


--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms. Please do not contact
me directly or ask me to contact you directly for assistance. If your
question is worth asking, it's worth posting.
 
J

jason kennedy

glue a piece of paper over the offending entry in the address bar

lo-tech, but it works

Jason
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,258
Messages
2,571,033
Members
48,768
Latest member
first4landlord

Latest Threads

Top