A little help needed passing hidden values to next page


Posted on 16th Feb 2014 07:03 pm by admin

I have a page that has hidden values in a form.

example
Code: <input name='signupID' type='hidden' value='1' />
<input name='signupID' type='hidden' value='2' />
<input name='signupID' type='hidden' value='3' />
<input name='signupID' type='hidden' value='4' />

also within this form, the user enters details, name, phone number etc.

On the next page i need these hidden values to compare to the ID in the database so i can update the rows based on this hidden value.

I have obviously taken a wrong route here becuase i am getting warning after warning.

The code i have tried is this:
Code: if(isset($_POST['signupID'])) {
foreach($_POST['signupID'] as $item) {
echo "<input name='signupID' type='hidden' value='". $item . "' />";

but i get this: Warning: Invalid argument supplied for foreach() in C:wwwwasp-control.co.uk on line 79

The idea is that once the user has filled in the form, hits submit, next page compares the database to these hidden values "1,2,3,4" and then updates the database where the ID in the database is "1,2,3,4"

Any help here would be great

No comments posted yet

Your Answer:

Login to answer
207 Like 26 Dislike
Previous forums Next forums
Other forums

order by date not ID number help php
I am trying to orginize the following code to order by date not id number.
any help would be grea

$get problem
Hi Guys ...

can you please tell me what i am doing wrong here
Code: <?php

update 2 columns by doing inner 2-column query
Hi,
is something like this possible?

update contract_all set col1,col2 =
(

Strange HTML Tag?
I recently noticed some odd HTML appear in some of the websites I host. Not all of them are run on a

More pug propaganda.
http://www.youtube.com/watch?v=8Kkrmubsgf8

The commercial is definitely worth watching pug aw

does anyone know a php script to send mail using gmails/googles free smtp server
cause i heard u can do that but i dont know how

background color imagefill
Hello

I would like to ask you why I see this square in red color just in my local xampp insta

Session variable help
I'm having a very troubling issue. Maybe I'm just looking over something but I have looked at the co

session checking in page load
hai all I have a web site is www.Mryas.com in this my login page is Page1.aspx its co

Attempt to assign property of non-object in...
I'm having issues with the following function in PHP 5...

function getTreeWithChildre

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash