Page 1 of 1

[SOLVED] form along with ids

Posted: Tue Sep 27, 2005 8:37 am
by dude81
Hello forum,
I have php page coming with page.php?id=2,
how do I pass such a thing in form action,
is it possible only thorugh href??

Posted: Tue Sep 27, 2005 8:40 am
by feyd

Code: Select all

action="form.php?id=2"
:?

it's recommended to pass it via the form itself however using a hidden field

Code: Select all

<input type="hidden" name="id" value="2" />

Posted: Tue Sep 27, 2005 8:46 am
by dude81
yup it works fine but at the same time it gets values like

Code: Select all

?id=2&x=47&y=9
where x and y are not being passed

Posted: Tue Sep 27, 2005 8:53 am
by feyd
explain more please. Where are these supposed to be coming from, the form? You'd need to use the method get to have more data passed via the url.

Posted: Wed Sep 28, 2005 11:49 pm
by dude81
SOLVED.I was using get method itself