Your IP : 216.73.217.87
| Current Path : /var/www/sick/bel/ |
|
|
| Current File : //var/www/sick/bel/s3.php |
<?php
header("Cache-Control: no-cache, must-revalidate");
header("Expires: Sat, 26 Jul 1997 05:00:00 GMT");
error_reporting(0);
?><!DOCTYPE HTML><html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<?php
include("./conn.php");
@mysql_select_db('bel', $db) or die();
function sql_safe($text)
{
return mysql_real_escape_string(trim($text));
}
function html_safe($text)
{
return htmlspecialchars(trim($text), ENT_QUOTES);
}
$words=$_POST["words"];
$words=html_safe($words);
$words=sql_safe($words);
$std=$_POST["std"];
$res=mysql_query("UPDATE `students` SET `z3`='".$words."' WHERE `i`='".$std."'", $db);
if ($res)
{
print("<script> window.parent.sscc(); </script>");
}
else
{
print("<script> window.parent.serr(); </script>");
}
?>
</head>
<body>
</body>
</html>