Jump to content

pick apart my query mistake


mike12255

Recommended Posts

Its time for bed but I have to finish this file before I go to bed and I cant figure out the mistake with my query hoping there are some fresh eyes out there that can see it.

 

Here is the line :

$query = $qls->Security->make_safe("INSERT INTO `{$qls->config['sql_prefix']}chat` (username, message) VALUES (\"$user\", \"$message\")");

when I die the statement I get:

 

 

 

INSERT INTO `qls3_chat` (username, message) VALUES ("mike12255", "TESTING FJFDHSJHDFISEJ")

 

I can take that and query that in through php my admin no problem but when i run a query through php code I get the error:

 

 

 

1064: 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 '"mike12255", "TESTING FJFDHSJHDFISEJ")' at line 1

 

Link to comment
https://forums.phpfreaks.com/topic/284499-pick-apart-my-query-mistake/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.