Announcement

Collapse
No announcement yet.

Twittercast: Shoutcast / Icecast Song Title To Twitter Status PHP Script

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #61
    Is there any way to get it to display the song titles. All I see on my page is Now Playing: 0 - Listeners

    The PC Radio Network: An upbeat variety of the 50s-Today!

    Comment


    • #62
      twiter casting

      ive edited the code but for some reason its not posting anyting can someone look at the code and help me out.

      thanks

      PHP Code:
      <?php 

      $timeout 
      "5"// Number of seconds before connecton times out - a higher value will slow the page down if any servers are offline

      $ip[1] = "66.96.29.176";  
      $port[1] = "8000"

      $servers count($ip); 
      $i "1"

      while(
      $i<=$servers
          { 
          
      $fp = @fsockopen($ip[$i],$port[$i],$errno,$errstr,$timeout); 
          if (!
      $fp)  
              {  
              
      $listeners[$i] = "0"
              
      $msg[$i] = "<span class=\"red\">ERROR [Connection refused / Server down]</span>"
              
      $error[$i] = "1"
              }  
          else 
              {  
              
      fputs($fp"GET /7.html HTTP/1.0\r\nUser-Agent: Mozilla\r\n\r\n"); 
              while (!
      feof($fp))  
                  { 
                  
      $info fgets($fp); 
                  } 
              
      $info str_replace('<HTML><meta http-equiv="Pragma" content="no-cache"></head><body>'""$info); 
              
      $info str_replace('</body></html>'""$info); 
              
      $stats explode(','$info); 
              if (empty(
      $stats[1]) ) 
                  { 
                  
      $listeners[$i] = "0"
                  
      $msg[$i] = "<span class=\"red\">ERROR [There is no source connected]</span>"
                  
      $error[$i] = "1"
                  } 
               
              
      $song[$i] = $stats[6]; 
                   
              } 
          
      $i++; 
          } 

      require(
      'twitterAPI.php'); 

      $fh = @fopen('title.txt''r+'); 
      $track = @fread($fhfilesize('title.txt')); 
      if (
      $track == $song[1]."\n"){ 
        
      fclose($fh); 
        die(
      0); 
      }else{ 
        @
      fclose($fh); // if it errors, then the file doesn't exist, and the stream was never open 
        
      $fh fopen('title.txt''w'); 
        
      fwrite($fh$song[1]."\n"); 
        if (
      strstr($song[1],"[Live!]")){

      $twitter_status=postToTwitter($twitter_username$twitter_psw'#YorkVilleStudio - Now Playing: '.$song[1] .' - ' .$total_listeners .' Listeners - http://yorkvillestudios.com');

      }
       

      fclose($fh); 

      ?>

      Comment


      • #63
        Is this project dead. I cant seem to get this to work either.

        Comment


        • #64
          Would be heavy if someone could host a working version of this, had the same problem for the past month now

          code:
          About to connect() to twitter.com port 80 (#0)
          * Trying 168.143.162.36...
          * Connected to twitter.com (168.143.162.36) port 80 (#0)
          authization stuff
          Host: twitter.com\r
          Accept: */*\r
          HTTP/1.1 413 Request Entity Too Large

          Much appreciated if someone does this im sure many people are after a new release/runinng release

          Comment


          • #65
            sorry must have deleted the file... the original download link in the very first post is working again.. sorry about that

            Comment


            • #66
              HI!
              Thx for this great app, it works nice.
              But I must open my browser all the time. If I close this, it will not work anymore.

              Is there a possibility that it works all the ime without open a browser?

              Thanks in advance
              Pieter, the Netherlands

              Comment


              • #67
                Hi I've been using this for sometime but its all of a sudden stopped working. My host stated there have not changed anything and I don't think twitter has blocked the script.

                my twitter page : http://www.twitter.com/summertimeradio
                my twittercast script http://www.summertimeradio.com/twitt...cast_multi.php

                Does anybody have an idea what this could be
                www.summertimeradio.com /Dance Music 24/7

                Comment


                • #68
                  Hello everyone,
                  I've tried several scripts but none works 100% for me. the point is that I have a problem with characters like áéçâêã, see the error in my twitter http://twitter.com/mixtotalfm (the first message has been posted by twitterscript and the last message by me)

                  When the message with the song title with special character is posted, then the twitter "cuts" the two letters from the front. Someone did the test using these characters? áéíóúã

                  I think it's something related to the type of character in the twitter API. Someone has any idea how to solve this problem?

                  Regards.

                  Comment


                  • #69
                    My script still isn't working but below is the error I'm getting when running it. I can confirm the output is less than 140 charaters and twitter hasn't blocked my IP address of host. Anybody can help? I'm able to post to twitter with other scripts that are running on my website

                    * About to connect() to twitter.com port 80 (#0)
                    * Trying 128.121.146.228... * connected
                    * Connected to twitter.com (128.121.146.228) port 80 (#0)
                    * Server auth using Basic with user 'summertimeradio'
                    > POST /statuses/update.xml?status=Is+Currently+Playing%3A+Pursuit+-+Classics+Mix HTTP/1.1
                    Authorization: Basic c3VtbWVydGltZXJhZGlvOnN1bW1lcjF0aW1lMg==
                    Host: twitter.com
                    Accept: */*
                    Content-Length: -1
                    Content-Type: application/x-www-form-urlencoded
                    Expect: 100-continue

                    < HTTP/1.1 413 Request Entity Too Large
                    < Date: Tue, 18 May 2010 19:11:38 GMT
                    < Server: hi
                    < Connection: close
                    < Content-Type: text/html; charset=iso-8859-1
                    <
                    * Closing connection #0
                    www.summertimeradio.com /Dance Music 24/7

                    Comment


                    • #70
                      Good to see another Joomla! user..
                      Go easy on me...
                      https://1mix.co.uk

                      Comment


                      • #71
                        Originally Posted by Biggus View Post
                        Hi I've been using this for sometime but its all of a sudden stopped working. My host stated there have not changed anything and I don't think twitter has blocked the script.

                        my twitter page : http://www.twitter.com/summertimeradio
                        my twittercast script http://www.summertimeradio.com/twitt...cast_multi.php

                        Does anybody have an idea what this could be
                        Hey Biggus i am with you on this issue,i noticed that my script stopped updating my twitter account just about the same date you posted this message.
                        Can we get some help with this please?
                        Our script has stopped working.

                        Comment


                        • #72
                          I uploaded my working version of Twittercast. Thanks again to Dopelabs for this script and thanks for helping me out in the thread.

                          Here's the link:

                          http://www.odiggy.com/shoutcastscrip...wittercast.zip

                          Note: I used stristr() so that the keyword "Live" was not case sensitive.

                          Also check out the quick little readme.txt I made. Oh and I don't think this will work with that new Shoutcast 2, it pulls the song info from 7.html.


                          Cheers!
                          Odogg
                          Dogglounge Internet Radio
                          Streaming Deep House Music 24/7
                          www.dogglounge.com

                          Comment


                          • #73
                            Originally Posted by odogg View Post
                            I uploaded my working version of Twittercast. Thanks again to Dopelabs for this script and thanks for helping me out in the thread.

                            Here's the link:

                            http://www.odiggy.com/shoutcastscrip...wittercast.zip

                            Note: I used stristr() so that the keyword "Live" was not case sensitive.

                            Also check out the quick little readme.txt I made. Oh and I don't think this will work with that new Shoutcast 2, it pulls the song info from 7.html.


                            Cheers!
                            Thanks for the updated folder Odogg, but i cant seem to get mine to work on my twitter page.I have the ip and port edited, also have my twitter and password edited. But nothing shows up on twitter.
                            Please help me if u can.

                            Comment


                            • #74
                              Hi,
                              Please can someone help me out with my script?Mine stopped working.Is there anything updating i need to do to make it work?Its obviously a twitter side issue.
                              I would really appreciate the help.
                              Thanks.

                              Comment


                              • #75
                                Hi,
                                Please can someone help me out with my script?Mine stopped working.Is there anything updating i need to do to make it work?Its obviously a twitter side issue.
                                I would really appreciate the help.
                                Thanks.

                                Comment

                                Working...
                                X