\n";
$from .= "Reply-To: meganizer@engsas.de\n";
$from .= "Content-Type: text/html\n";
$countManus = 0;
$countMintypes = 0;
$countPrefixes = 0;
$connId = @ mysql_connect("localhost", Settings::value("SUBMITUSER"), Settings::value("SUBMITPASSWORD"));
if(!$connId){
$subject = "ManuServer - Could not connect to the database";
$body = "Could not connect to the database";
mail($reciever, $subject, $body, $from);
}
else{
if(!mysql_select_db(Settings::value("DBNAME"))){
$subject = "ManuServer - Could not select the database";
$body = "Could not select the wanted database";
mail($reciever, $subject, $body, $from);
mysql_close($connId);
}
else{
$res = mysql_query("SELECT id FROM manufacturerhasmins_queue");
$countPrefixes = mysql_num_rows($res);
$res = mysql_query("SELECT id FROM mintypes_queue");
$countMintypes = mysql_num_rows($res);
$res = mysql_query("SELECT id FROM manufacturers_queue");
$countManus = mysql_num_rows($res);
mysql_close($connId);
}
}
if(($countManus > 0) || ($countMintypes > 0) || ($countPrefixes > 0)){
$subject = "ManuServer - Pending items: ". $countManus ." Manufacturers, ". $countMintypes ." MIN-Types, ". $countPrefixes ." Prefixes";
$body = "Their are queued items for the ManuServer.
";
$body .= "