php - Is there any way to check the id of a $_POST variable? -


i need distinguish 2 variables being passed form. important these 2 variables have same name. because of have given them different ids (but classes, doesn't matter in application). need know if there way @ $_post variable, , have php tell me id before lumped in array of values same name.

you can have 2 different form fields same name if create array name, such as:

<input type="text" name="category[]" value="red" /> <input type="text" name="category[]" value="blue" /> 

then when you've posted form values can examine $_post value var_dump(), such as:

<?php var_dump($_post); ?> 

and can retrieve values array.


Comments

Popular posts from this blog

php - Admin SDK -- get information about the group -

dns - How To Use Custom Nameserver On Free Cloudflare? -

Python Error - TypeError: input expected at most 1 arguments, got 3 -