Z?v?? Posted April 10, 2007 Posted April 10, 2007 I have added a new field to my items table and now when I got to create an item in my staff panel (on v2) it gives me the QUERY ERROR: Column count doesn't match value count at row 1 I know I have to add something into the staff_items.php file but I don't know exactly how to do it. I believe this is the part of staff_items.php that needs edited... $m=$db->query("INSERT INTO items VALUES('',{$_POST['itmtype']},'$itmname','$itmdesc',{$_POST['itmbuyprice']},{$_POST['itmsellprice']},$itmbuy, '{$_POST['effect1on']}', '$efx1', '{$_POST['effect2on']}', '$efx2', '{$_POST['effect3on']}', '$efx3', $weapon, $armor)"); print "The {$_POST['itmname']} Item was added to the game."; stafflog_add("Created item {$_POST['itmname']}"); Quote
seanybob Posted April 10, 2007 Posted April 10, 2007 Re: Column Count Error. $m=$db->query("INSERT INTO items VALUES('',{$_POST['itmtype']},'$itmname','$itmdesc',{$_POST['itmbuyprice']},{$_POST['itmsellprice']},$itmbuy, '{$_POST['effect1on']}', '$efx1', '{$_POST['effect2on']}', '$efx2', '{$_POST['effect3on']}', '$efx3', $weapon, $armor, '')"); print "The {$_POST['itmname']} Item was added to the game."; stafflog_add("Created item {$_POST['itmname']}"); Quote
Z?v?? Posted April 10, 2007 Author Posted April 10, 2007 Re: Column Count Error. Thank bro, worked perfect. +1 Quote
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.