require("include/top.php");
if (($SESSION_LEVEL=='administrator' || $SESSION_LEVEL=='moderator' || $SESSION_LEVEL=='gloperator')):
unset($submitok);
// check the submitted data
if($prod && $type && $link)
{
if(!$type)
$errormessage[]="having a type would be nice..";
if(!$link)
$errormessage[]="no download link ?!";
else
{
$myurl=parse_url($link);
if(($myurl["scheme"]!="http")&&($myurl["scheme"]!="ftp")&&($myurl["scheme"]!="https"))
$errormessage[] = "only http/https and ftp protocols are supported for the download link";
if(strlen($myurl["host"])==0)
$errormessage[] = "missing hostname in the download link";
if(strstr($myurl["path"],"incoming"))
$errormessage[] = "the file you submitted is in an incoming path, try to find a real path";
}
if(!$errormessage)
$submitok=true;
}
// insert the submitted download link
if($submitok){
$query = "INSERT INTO downloadlinks SET ";
$query.= "downloadlinks.prod='".$prod."', ";
$query.= "downloadlinks.type='".$type."', ";
$query.= "downloadlinks.link='".$link."'";
//print($query);
mysql_query($query);
}
?>
the lobster says "NO ENTRANCE!"
you need god priveligies to access this place.
else: ?>