hi just to note i also tried writing the output to a FILE AS WELL (to check) and this also fails !! here is the code
<html>
<head>
<meta http-equiv="refresh" content="500">
<title></title>
</head>
<body>
<?php
$File = "YourFile.txt";
$Handle = fopen($File, 'w');
$arrow="----------------------------------------";
$Locatie="Greece";
//mysql shit
$link=mysql_connect('127.0.0.1','root','');
if(!$link) die("Could not connect to MySQL");
$database = "airnav";
mysql_select_db($database,$link)
or die ("Could not connect to database");
//airnav
$fp = fsockopen("tcp://127.0.0.1",7879);
while (!feof($fp))
{
$buff1=fgets($fp, 2048);
echo $buff1;
if (strlen($buff1)<>0)
{
$numbers = explode("</MODESMESSAGE>", $buff1,-1);
for($i = 0; $i < count($numbers); $i++)
{
$DateVar = explode("</DATETIME>", $numbers[$i]);
$DateVarModes = strstr($DateVar[0], "<DATETIME>");
$DateVarJaar = substr($DateVarModes,10,4 );
$DateVarMaand = substr($DateVarModes,14,2 );
$DateVarDag = substr($DateVarModes,16,2 );
$DatumString=$DateVarJaar."-".$DateVarMaand."-".$DateVarDag;
if (strlen($DateVarJaar)<>0)
{
$DateVarUur = substr($DateVarModes,18,2 );
$DateVarMin = substr($DateVarModes,20,2 );
$DateVarSec = substr($DateVarModes,22,2 );
$TijdString=$DateVarUur.":".$DateVarMin.":".$DateVarSec ;
if (strlen($DateVarUur)<>0)
{
$CallsVar = explode("</CALLSIGN>", $numbers[$i]);
$CallsVarModes = strstr($CallsVar[0], "<CALLSIGN>");
$CallsVarModes = substr($CallsVarModes,10,50 );
$TweedeElement=$CallsVarModes;
$HexVar = explode("</MODES>", $numbers[$i]);
$HexVarModes = strstr($HexVar[0], "<MODES>");
$HexVarModes = substr($HexVarModes,7,50 );
$DerdeElement=$HexVarModes;
if (strlen($DerdeElement)<>0)
{
if (strlen($TweedeElement)==0)
{
$TweedeElement="---";
}
$query = "INSERT INTO `live` (a,b,c,d,e) VALUES ('$DerdeElement','$DatumString','$TijdString','$TweedeElement','$Locatie')";
fwrite($Handle, $arrow);
fwrite($Handle, $DerdeElement);
fwrite($Handle, $DatumString);
fwrite($Handle, $TijdString);
fwrite($Handle, $TweedeElement);
fwrite($Handle, $Locatie);
fwrite($Handle, $Locatie);
fwrite($Handle, $arrow);
print "Data Written";
fclose($Handle);
echo $DerdeElement."\n";
echo $DatumString."\n";
echo $TijdString."\n";
echo $TweedeElement."\n";
echo $Locatie."\n";
mysql_query($query,$link);
echo $query."\n";
//
// Use this script off line ?
// Remove the // signs for the commands below.
//
//$query = "INSERT INTO `live` (a,b,c,d,e) VALUES ('$DerdeElement','$DatumString','$TijdString','$TweedeElement','$Locatie');";
//$handle1 = fopen("$DatumString mysqllog.txt", 'a');
//fwrite($handle1, $query);
//fwrite($handle1, "\r\n");
//fclose ($handle1);
}
}
}
}
}
else
{
echo "Buffer Empty"."\n";
// CheckSocket($fp,$Locatie);
}
}
mysql_close($link);
?>
<a href="2.php">check database contents</a>
</body>
</html>
im using the latest radarbox version in hardware and software i only bought it one week ago
now ill try what you suggested me