kjetilbmoe
8th September 2003, 11:33
Hi,
i'm trying to perform a local directory test, to see if the server is off, on--line, or broadcasting. See the code snippet below.
<?php
$l = fsockopen('10.0.0.4', 8000, $errn, $errs, 1);
if ($l == FALSE) echo $errn . ' . ' . $errs;
else {
fwrite ($l, "icy-metadata:1\r\n"); $txt = fgets ($l, 100);
echo strlen($txt);
}
?>
but this is not working. Am I u sing the right headres. The problem is that I do not receive any text when sending the first header. Does anyone see my problem?
i'm trying to perform a local directory test, to see if the server is off, on--line, or broadcasting. See the code snippet below.
<?php
$l = fsockopen('10.0.0.4', 8000, $errn, $errs, 1);
if ($l == FALSE) echo $errn . ' . ' . $errs;
else {
fwrite ($l, "icy-metadata:1\r\n"); $txt = fgets ($l, 100);
echo strlen($txt);
}
?>
but this is not working. Am I u sing the right headres. The problem is that I do not receive any text when sending the first header. Does anyone see my problem?