FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » test if $_POST variable is set
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
test if $_POST variable is set [message #175831] Sat, 29 October 2011 05:40 Go to previous message
cerr is currently offline  cerr
Messages: 33
Registered: September 2010
Karma:
Member
Hi There,

I have a form with various checkboxes, they got names i have from a db
to identify them.
Now I would like to check what has been posted by the form. For that I
would like to read all the field names from the db and check if they
have been set something like this:

$result = mysql_query("SELECT * FROM specialty");
while($row = mysql_fetch_array($result)) {
if (isset($_POST[$row['name']])) {
var_dump($POST);
session_unset();
}

But this doesn't seem to work the way I expected it to? I.e. I would
liek to check if $_POST['MyCheckbox'] is set now but MyCheckbox is a
name from the database. How do I do this best, the easiest way?

Thanks,
Ron
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: `********AMAZING HOT PHOTOS & VIDEOS ********
Next Topic: Suche Buch zur OOA/OOD
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Nov 24 20:41:58 GMT 2024

Total time taken to generate the page: 0.03874 seconds