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
26
Other forums
Save username into DB
OkaY so I got my blog to actually save the posts and whatever, all I need now is for it to keep the
Add_Months not Easy to Understand
Oracle is number 1, very fast and very easy. But....
OK, I think but have a problem, only 1 pro
Accept only alpha characters
I've got this bit of code ready for accepting a phrase:
Code: if (!eregi ("", $_POS
Find current logon time
Hi,
in my sql script i want to query and find out the logon time of the current session.
<
undefined offset help
Hi All,
I kept getting undefined offset PHP notice for a simple for loop. For eg
$va = arr
INSERT data problem!
After having an string with apostrophes ', double quotes " or any other special characters, suc
PHP & Java
Hello,
can PHP code be used inside java code?
Code: [Select]<SCRIPT LANGUAGE=&q
Local file browser with php
Halo..
So this is what i want to create. I have a folder that i share and it has many movies.
Wrong Info sent Using $get in form
Hi i have this code that i tried to make to send some info from one page to aother with lots of ppls
weeks in a year
hi,
i found this snippet on php.net
QuoteFor the week number for weeks starting on Sunday: