ali_2kool2002 Posted March 10, 2007 Share Posted March 10, 2007 Hi im using the line below in a while loop, but i want to be able to select multiple submit buttons at one time so,but at the moment im not sure how to change the name of the button as it could be a while loop for x amount of times...i could count how manytimes i need to go throught the loop and then output the submit button but then how do i change the name in this loop automatically? does this help...im on here so ne qns just reply and il answer within a few secs... while($i<$count && $results = mysql_fetch_array($result, MYSQL_ASSOC)){ <td align="center"><input type="radio" name= "txtbox[]" value = '.$orderId.' unchecked> Selected</td> Link to comment https://forums.phpfreaks.com/topic/42114-solved-submit-button/ Share on other sites More sharing options...
aniesh82 Posted March 10, 2007 Share Posted March 10, 2007 Hello Friend, Can you please explain your problem ? I couldnot understand your need...If so I can help you. Regards Aniesh Joseph Link to comment https://forums.phpfreaks.com/topic/42114-solved-submit-button/#findComment-204262 Share on other sites More sharing options...
ali_2kool2002 Posted March 10, 2007 Author Share Posted March 10, 2007 problem is on a user level that i need to be able to select more than one submit button...but from my code i can only select one submit button at one time...this is due to the name being the same in the submit button code name= "txtbox[]" i need someone to be able to change the name for each submit button that is displayed every time the while loop goes round. hope this helps? ??? ??? Link to comment https://forums.phpfreaks.com/topic/42114-solved-submit-button/#findComment-204264 Share on other sites More sharing options...
aniesh82 Posted March 10, 2007 Share Posted March 10, 2007 Hello This loop creates 10 submit button with different names. $x =1; while($x<=10) { $button_name = "submit".$x; ?> <input type="submit" name="<?=$button_name ?>" value="Submit<?=$x?>"> <? } Regards Aniesh Joseph Link to comment https://forums.phpfreaks.com/topic/42114-solved-submit-button/#findComment-204269 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.