Welcome Guest, Not a member yet? Register   Sign In
Mystery Post Values appearing
#1

[eluser]johnwbaxter[/eluser]
I turned on the profiler today to check something and i've noticed an odd couple of post values that should not exist;

Code:
$_POST['x']       11
$_POST['y']       14

With every page submit (it's a form that allows you to calculate something over and over) the values change.

What is mildly worrying is that in my view and of course the source code of the rendered page there are no form elements with the name x or y. Not hidden not nothing.

Where on earth could this be coming from?!

I have no analytics running or anything like that, no hooks either. I can't work out for the life of me where this is coming from!

Can anyone give me some suggestions on where to look to find what's generating this being as it's not in the view?
#2

[eluser]xwero[/eluser]
Do you have an image submit with no name?
#3

[eluser]GSV Sleeper Service[/eluser]
those are the x and y coordinates of the submit button/image!
#4

[eluser]xwero[/eluser]
That was my guess too Smile
#5

[eluser]johnwbaxter[/eluser]
What! Are you serious? I do have an image as a submit button. I've never heard of that before! Why does it submit the x and y co-ordinates of the image?!
#6

[eluser]GSV Sleeper Service[/eluser]
it's quite useful, you could, for example use a map as a submit button and tell users to 'click on your location'
as for why. ask the W3C - http://www.w3.org/TR/html4/interact/forms.html#h-17.4.1
Quote:When a pointing device is used to click on the image, the form is submitted and the click coordinates passed to the server. The x value is measured in pixels from the left of the image, and the y value in pixels from the top of the image. The submitted data includes name.x=x-value and name.y=y-value where "name" is the value of the name attribute, and x-value and y-value are the x and y coordinate values, respectively.
#7

[eluser]johnwbaxter[/eluser]
Thank you very much for both the prompt response and the info!

I was worrying a bit there, "what sort of black magic is this?!" i thought.

Cheers!




Theme © iAndrew 2016 - Forum software by © MyBB