[Help] Radio Status Problem

malemees

Member
Joined
Jun 22, 2009
Messages
107
Reaction score
22
Hi all! I have a problem with my radio status script. My radio is online but script saing offline :S (shoutcast & listen2myradio)

I use following script:

status.php
PHP:
<?php
if(file_get_contents('radiocheck.php') == 'Online') {
    echo '<img src="url/Online.JPG" alt="Radio station online" />';
}else{
        echo '<img src="url/Offline.JPG" alt="Radio station offline" />';
}
?>

and radiocheck.php

PHP:
<?php

error_reporting(0);
if(fsockopen('IP',6615,$errno, $errstr, 5)) {
        echo 'Online';
}else{
        echo 'Offline';
}
 
1. do you have router?
2. ttry with this code ...
<?php

error_reporting(0);
if(fsockopen('PUT YOU IP HERE',6615,$errno, $errstr, 5)) {
echo 'Online';
}else{
echo 'Offline';
}
?>
this should be you radiocheck.php
 
Put it in one file and it's ok also file_get_contents is not used properly....

<?php
if(fsockopen('IP',6615,$errno, $errstr, 5))
{
echo '<img src="url/Online.JPG" alt="Radio station online" />';
}else{
echo '<img src="url/Offline.JPG" alt="Radio station offline" />';
}
?>
 
  • Like
Reactions: malemees