in my project i am using multiple combo boxes in a single can u help me how to get values from those me used nearly 400 it is very difficult to use 400 variables to retrive value from me used array here me not able to use array variable in get or post showing can u help me plz its very aurgent!

Recommended Answers

All 3 Replies

On your page give same id to all the combo boxes and place [] after their id. On your php page use this.

// I assume the id of all the boxes to be [B]boxes[][/B]
$boxes = $_POST['boxes'];

foreach($boxes as $k){
echo $k;    // will display the selected value of each combo box
        	// Or what you want to do with the boxes

i am using array variables to get the values eg
i have to use variables as mentioned above

it is wrong $_POST is correct and instead of [1] use foreach loop.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.