Icecast Streaming Media Server Forum Index Icecast Streaming Media Server
Icecast is a Xiph Foundation Project
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Help with a fsockopen call?

 
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Source Clients
View previous topic :: View next topic  
Author Message
mzimmers



Joined: 06 Oct 2008
Posts: 2

PostPosted: Wed Oct 08, 2008 2:26 am    Post subject: Help with a fsockopen call? Reply with quote

I'm really new to some of this stuff, so I'd appreciate some assistance here. I pulled this code segment from the Nicecast manual. It's always returning false...can someone give me an idea what I'm doing wrong?

My stream is coming from http://75.25.129.111:8000/listen.m3u.

Code:
<?php
   function onAirTest($ipaddress, $port)
   {
      if ($ret = @fsockopen($ipaddress, $port, $errno, $errstr, 1))
      {
         fclose($ret);
         return true;
      }
      else
         {
         return false;
         }
   }
?>

<?php
/*
   if (onAirTest("75.25.129.111", "8000"))
   {
      print "Radio SilverBar Is Currently On The Air";
   }
   else
   {
      print "Radio SilverBar Is Currently Off The Air";
   }


Thanks.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Icecast Streaming Media Server Forum Index -> Source Clients All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2002 phpBB Group
subRebel style by ktauber