Jump to content

You have an error in your SQL syntax; check the manual that corresponds ....


Username:

Recommended Posts

$pastelink = "<br /><a href='view.php?paste=$lol&language=$language'>$name</a>";
mysql_query("INSERT INTO recent (url) VALUES ('$pastelink')");

 

That query won't run, however if I do this:

 

$test = $_POST['name'];
//$pastelink = "<br /><a href='view.php?paste=$lol&language=$language'>$name</a>";
mysql_query("INSERT INTO recent (url) VALUES ('$test')");

 

It will run, is this because of the single quotes in $pastelink?

 

& If so, how can I fix it?

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.