chaoswar4u Posted May 10, 2007 Share Posted May 10, 2007 The code in question is function remove_friend() { global $db,$ir,$c,$userid; $db->query("DELETE FROM contactlist WHERE cl_ID={$_GET['f']} AND cl_ADDER=$userid"); print "Contact list entry removed! > Back"; } $h->endpage(); ?> The error is when you try to remove a contact. The error is QUERY ERROR: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'AND cl_ADDER=1' at line 1 Query was DELETE FROM contactlist WHERE cl_ID= AND cl_ADDER=1 Any help would be great and many thx in advance for any replies. Quote Link to comment Share on other sites More sharing options...
hamster01 Posted May 10, 2007 Share Posted May 10, 2007 Re: Contacts Error? Its not picking up the script.php?f=1 Check the links ;) Quote Link to comment Share on other sites More sharing options...
Silver Posted May 10, 2007 Share Posted May 10, 2007 Re: Contacts Error? Replace the query u have with: $db->query("DELETE FROM contactlist WHERE cl_ID='{$_GET['f']}' AND cl_ADDER='$userid'"); Quote Link to comment Share on other sites More sharing options...
chaoswar4u Posted May 10, 2007 Author Share Posted May 10, 2007 Re: Contacts Error? Replaced with your query. It says contact deleted but it still remains in the list????????????????? However no error this time but it just dosent do what it says it should do. Quote Link to comment Share on other sites More sharing options...
chaoswar4u Posted May 16, 2007 Author Share Posted May 16, 2007 Re: Contacts Error? Can anyone please help me out on this one.? Quote Link to comment Share on other sites More sharing options...
Decepti0n Posted May 16, 2007 Share Posted May 16, 2007 Re: Contacts Error? whats the page/part that actually lists the contacts Quote Link to comment Share on other sites More sharing options...
chaoswar4u Posted May 16, 2007 Author Share Posted May 16, 2007 Re: Contacts Error? The page at the start that shows the list of contacts is contactlist.php and then when you try to remove the contact its contactlist.php?action=remove&f= Quote Link to comment Share on other sites More sharing options...
stryker Posted May 17, 2007 Share Posted May 17, 2007 Re: Contacts Error? optimize that table and then try agin, this happens alot when a table is overloaded with memory it sometimes glitches Quote Link to comment Share on other sites More sharing options...
Z?v?? Posted May 19, 2007 Share Posted May 19, 2007 Re: Contacts Error? I'm having this same exact problem on my v2 game as well. It doesnt delete from the contact list. Quote Link to comment Share on other sites More sharing options...
chaoswar4u Posted May 21, 2007 Author Share Posted May 21, 2007 Re: Contacts Error? Well here ya go peeps. I found the problem myself. open contactlist.php Find <td>Remove</td> and replace with <td>Remove</td> Tried and tested. Works Quote Link to comment 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.