this is what I have so far:
include "config.php";
if (@$_POST['search']=="search")
{
$keyword=$_POST['keyword'];
$result=mysql_query("SELECT * FROM listed WHERE `itemname` LIKE '%$keyword%' OR `message1` LIKE '%$keyword%'");
while ($results = mysql_fetch_array($result))
{
$tag=$results['tag'];
$idno=$results['id'];
$title=$results['name'];
$description=$results['message1'];
$position=40;
$post = substr($description, 0, $position);
echo "$tag,$title,$post,$idno
?>
I also heard of adding a thing called noslashes or something which is supposed to prevent unwanted SQL queries. Any info on that?
2006-09-30
02:48:58
·
2 answers
·
asked by
detroitkid17
2
in
Computers & Internet
➔ Programming & Design