Page 1 of 1
help with passing a hidden array
Posted: Sun Jun 30, 2002 11:06 pm
by chris12295
I need to pass an array to my php script but i need the values to be a hidden form element. How can i do this?
Posted: Sun Jun 30, 2002 11:34 pm
by hob_goblin
<input type="hidden" name="array['key']" value="value" />
<input type="hidden" name="array['key2']" value="value" />
<input type="hidden" name="array['key2']" value="value" />
Posted: Mon Jul 01, 2002 1:58 am
by twigletmac
If there's a lot of values it may be easier to use sessions instead.
Mac
Posted: Mon Jul 01, 2002 2:17 am
by hob_goblin
true, or maybe you could do like
<input type="hidden" name="parseme" value="value|value2|value3" />
and then do like
$finalvar = explode("|", $parseme);