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... Quote 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']? Quote 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 Quote 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'] Quote 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. Quote 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!? Quote 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 Quote Link to comment https://forums.phpfreaks.com/topic/157627-solved-posting-help/#findComment-831858 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.