unemployment Posted May 5, 2011 Share Posted May 5, 2011 How can I prioritize the data posted. Right now this if statements are being posted at different times. If I hit submit and all the if statements post to mysql it is saying that they all receive the same time stamp, but the data is never posted in the same order. Can I order the posting process in php? if ((isset($_POST['companywebsiteas'])) && ($_POST['companywebsiteas'] != $r['companywebsite'])) { $details = $_POST['companywebsiteas']; update_company_actions($info['companyid'], 18, $details); } if ((isset($_POST['companyindustryas'])) && ($_POST['companyindustryas'] != $info['industry'])) { $details = $_POST['companyindustryas']; update_company_actions($info['companyid'], 17, $details); } if ((isset($_POST['companystageas'])) && ($_POST['companystageas'] != $info['stage'])) { $details = $_POST['companystageas']; update_company_actions($info['companyid'], 10, $details); } if ((!isset($_POST['companystateas'])) && (($_POST['companycountryas'] != $info['country']) || ($_POST['companycityas'] != $info['city']))) { $details = $_POST['companycityas'].', '.$_POST['companycountryas']; update_company_actions($info['companyid'], 11, $details); } else if ((isset($_POST['companystateas'], $_POST['companycityas'])) && (($_POST['companystateas'] != $info['state']) || ($_POST['companycityas'] != $info['city']))) { $details = $_POST['companycityas'].', '.$_POST['companystateas']; update_company_actions($info['companyid'], 11, $details); } Quote Link to comment https://forums.phpfreaks.com/topic/235569-prioritize-data-posted/ Share on other sites More sharing options...
vicodin Posted May 5, 2011 Share Posted May 5, 2011 You can make another row to define your priority. So like if the time stamps match then you can sort by their priority number. Quote Link to comment https://forums.phpfreaks.com/topic/235569-prioritize-data-posted/#findComment-1210738 Share on other sites More sharing options...
unemployment Posted May 5, 2011 Author Share Posted May 5, 2011 You can make another row to define your priority. So like if the time stamps match then you can sort by their priority number. Make another row? make a column in the db? is that what you mean? Quote Link to comment https://forums.phpfreaks.com/topic/235569-prioritize-data-posted/#findComment-1210832 Share on other sites More sharing options...
unemployment Posted May 5, 2011 Author Share Posted May 5, 2011 Can I receive any more help on this? I'd really rather not create another row in mysql. Quote Link to comment https://forums.phpfreaks.com/topic/235569-prioritize-data-posted/#findComment-1211005 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.