Viewing file: changeNews.inc.php3 (1.13 KB) -rwxr-xr-x Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?
if(checkSuperSession($superSession, $REMOTE_ADDR))
{
$userId2 = getUserSUId($superSession);
$userInfo = getUserInfo($userId2);
if(($userInfo[SuperUser] == 1) && ($userInfo[manageNews]==1) && ($userInfo[active]==1))
{
require("$mysqlCall");
$query = "replace into $news values('$newsId', '$title', '$details', '$date', '$itemID', '$userId', 'slag',)";
$mysql_result=mysql_query($query) or die(mysql_error());
if($mysql_result)
{
print("Looks as though that worked :)");
print "<META HTTP-EQUIV=\"Refresh\" CONTENT=\"1; URL=index.php3?mode=listNews&superSession=$superSession\">";
}
else
{
print("Something Wrong Here");
}
}
else
{
print("You do not have acess to this function");
}
}
else
{
/* session is bad */
print("Bad Session ID ($superSession)!<BR>\n");
$superSession = "";
}
?>
|