nightcrawler Posted May 17, 2007 Share Posted May 17, 2007 Not sure how the syntax is supposed to work for Update Queries with POST data. Help Please. $q = "UPDATE articles SET sub=$_POST['c'], title=$_POST['t'], name=$_POST['n'], email=$_POST['e'], date=$_POST['d'], description=$_POST['d'] WHERE id=$_POST['articleid'] LIMIT 1"; Quote Link to comment https://forums.phpfreaks.com/topic/51809-solved-mysql-update-syntax-help/ Share on other sites More sharing options...
vbnullchar Posted May 17, 2007 Share Posted May 17, 2007 Not sure how the syntax is supposed to work for Update Queries with POST data. Help Please. $q = "UPDATE articles SET sub=$_POST['c'], title=$_POST['t'], name=$_POST['n'], email=$_POST['e'], date=$_POST['d'], description=$_POST['d'] WHERE id=$_POST['articleid'] LIMIT 1"; <?php $q = "UPDATE articles SET sub='$_POST[c]', title='$_POST[t]', name='$_POST[n]', email='$_POST[e]', date='$_POST[d]', description='$_POST[d]' WHERE id='$_POST[articleid]' LIMIT 1"; ?> Quote Link to comment https://forums.phpfreaks.com/topic/51809-solved-mysql-update-syntax-help/#findComment-255265 Share on other sites More sharing options...
nightcrawler Posted May 17, 2007 Author Share Posted May 17, 2007 cool, thanks, marking as resolved Quote Link to comment https://forums.phpfreaks.com/topic/51809-solved-mysql-update-syntax-help/#findComment-255273 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.