Code Test

Posted by Vicks on Saturday, January 21, 2012 , in

$title = $_POST['title'];
$content = $_POST['content'];
if(!get_magic _quotes_gpc())
{
$title = addslashes($title);
$content = addslashes($content);
}

include 'library/config.php';
include 'library/opendb.php';

$query = " INSERT INTO news (title, content) ".
" VALUES ('$title', '$content')";
mysql_query($query) or die('Error ,query failed');
include 'library/closedb.php';
echo "Article '$title' added";
}


tables testing

column 1 column 2 column 3

Share This Post

1 comments:

Post a Comment