sseeley Posted May 10, 2009 Share Posted May 10, 2009 I have a number of records to post and update, around 100 at a time. I have all the records selected and reported back. I am running this code to increment the $_POST value $postID = $post . $i; echo "<input type=\"input\" name=$postID id=$postID value=$userID>"; When the records are posted I then need to work with this code, but I am unsure how to increment the $_POST['postID']? I hope someone can help me. Many thanks in advance... Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/ Share on other sites More sharing options...
Ken2k7 Posted May 10, 2009 Share Posted May 10, 2009 What do you mean increment $_POST['postID']? Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/#findComment-831212 Share on other sites More sharing options...
PFMaBiSmAd Posted May 11, 2009 Share Posted May 11, 2009 If you use an array and set the index of each array element to the specific id that you want, your code will be real simple - http://www.php.net/manual/en/faq.html.php#faq.html.arrays Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/#findComment-831256 Share on other sites More sharing options...
sseeley Posted May 11, 2009 Author Share Posted May 11, 2009 Yes I need to increment $_POST['post'] Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/#findComment-831806 Share on other sites More sharing options...
jackpf Posted May 11, 2009 Share Posted May 11, 2009 Like PFMaBiSmAd said, if you put your inputs into an array it'll make it a lot easier as you can just use a foreach loop. Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/#findComment-831820 Share on other sites More sharing options...
Ken2k7 Posted May 11, 2009 Share Posted May 11, 2009 Yes I need to increment $_POST['post'] What does that mean!? Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/#findComment-831849 Share on other sites More sharing options...
Daniel0 Posted May 11, 2009 Share Posted May 11, 2009 Yes I need to increment $_POST['post'] What does that mean!? http://dictionary.reference.com/browse/increment Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/#findComment-831858 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.