vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   Forum Home Enhancements - Shoutcast Status 3 (VB4) (https://vborg.vbsupport.ru/showthread.php?t=238209)

ShogunLord 04-19-2010 08:34 PM

I have triple checked everything, believe me...

It still reports as being off line....

butty 04-19-2010 08:44 PM

hi zach great mod still using it on vb3 and gona be upgrading to vb4 soon. also would really like it working on the cms also

maidos 04-28-2010 11:05 AM

using icecast here and i cant get the radio to work
i entered the correct pw and the server ip including port but doesnt work
as icecast it should recuire to enter a
mountpoint entry which your add onn doesnt so need help

Zachariah 04-28-2010 12:26 PM

Quote:

Originally Posted by maidos (Post 2028498)
using icecast here and i cant get the radio to work
i entered the correct pw and the server ip including port but doesnt work
as icecast it should recuire to enter a
mountpoint entry which your add onn doesnt so need help

This is for shoutcast not icecast. I plan to make a icecast version.

Alien 04-29-2010 08:53 PM

Is there a way to get this information on a separate page other than the forumhome?

Let's say "radio.php", if you have a dedicated radio page?

Zachariah 04-29-2010 08:57 PM

Quote:

Originally Posted by Alien (Post 2029232)
Is there a way to get this information on a separate page other than the forumhome?

Let's say "radio.php", if you have a dedicated radio page?

I'll work on a VB version, but I do have a standalone I made.
http://www.szone.us/f6/standalone-ph...cast-status-5/

Juggernaut 05-01-2010 05:14 PM

Couldn't get it to work following these instructions, will have to uninstall :(

maidos 05-02-2010 03:08 PM

Quote:

Originally Posted by Zachariah (Post 2028534)
This is for shoutcast not icecast. I plan to make a icecast version.

ok thanks :)
can we know maybe an eta when this can get released.

Alien 05-02-2010 04:53 PM

Quote:

Originally Posted by Zachariah (Post 2029235)
I'll work on a VB version, but I do have a standalone I made.
http://www.szone.us/f6/standalone-ph...cast-status-5/

Excellent! Thank you so much! I'm setting up a completely dedicated radio page and this would be excellent on top.

coberr 05-06-2010 12:36 AM

Quote:

Originally Posted by karkey (Post 2009435)
I have been doing abit of customizing :P

On our login bar when you are logged in

https://vborg.vbsupport.ru/showpost....5&postcount=64

Zachariah, How can I do this ?

Please help me ...

TeknoSounds 05-17-2010 01:13 AM

greetings, I'm trying to get this to show up for my vbAdvanced portal page. I have to pass the proper variables for it to show up on the forum page. Any help with this?
I've added the scast variable, but still no luck :(

TeknoSounds 05-21-2010 01:49 AM

Greetings, any help getting this working on other pages besides FORUMHOME and the presets for this?
Would really like to get this into my vBAdvanced either as it shows up when placed above the forums or as a module.

Zachariah 05-21-2010 04:19 AM

Quote:

Originally Posted by TeknoSounds (Post 2040918)
Greetings, any help getting this working on other pages besides FORUMHOME and the presets for this?
Would really like to get this into my vBAdvanced either as it shows up when placed above the forums or as a module.

Well there is a forumhome hook used to make it show on forumhome.
- edit that plugin and try to move it to global_start or global_complete.
- scast variable

Not sure on the results. I plan to make a vbadvanced block out of it soon.

TeknoSounds 05-21-2010 04:20 AM

Thanks muchly Zachariah :D Will be looking forward to the module! In that case I'll just try the hook move and see if I can get it to show.

TeknoSounds 05-21-2010 04:49 AM

Mmk, so changed it to global_complete in the plugin.
Under options, I set it to Custom.
Inserted {vb:raw scast} in the navbar template after the breadcrumb div (trying to set it in the same place (over/under) as VSA Donation bar, tho that is set by the plugin)

Still nothing showing though, doesn't even show in the main forums. :(
Any ideas?

For my forums, please click the first link in my sig.

p@ndu 05-21-2010 04:21 PM

though i followed all instructions its always showing server offline but im starming in in other way

now what should i do??

plz help me in getting this.......

maidos 05-23-2010 02:21 PM

Quote:

Originally Posted by indianhacker (Post 2041442)
though i followed all instructions its always showing server offline but im starming in in other way

now what should i do??

plz help me in getting this.......

maybe you are using icecast as me. this mods is just for shoutcast server

wired420 05-23-2010 06:20 PM

Quote:

Originally Posted by Zachariah (Post 2040965)
Well there is a forumhome hook used to make it show on forumhome.
- edit that plugin and try to move it to global_start or global_complete.
- scast variable

Not sure on the results. I plan to make a vbadvanced block out of it soon.

I'd like to be able to attach this to the VB navbar or header section so it shows on every page on the site. Would keep this installed if I could do that. Most of my users stay in the chatbox or cms and not so much in the forums.

TeknoSounds 05-26-2010 01:39 AM

Something interesting. At work I have WinXP and the WMP link loads up fine and shows the player. However at home I'm using Win7 and the window will continually show "loading..." though the audio stream will play.

Xencored 05-26-2010 11:07 PM

Holysh*t cant belive ive only just seen this!!!

Tagged (will be using this :D)

p.s hope you had a good day on the 18th Zach :D you and me have the same day :)

xabo 05-28-2010 08:29 PM

Hello,

First of all, thanks for a nice hack.

Anyhows im having a question, is there any chance to implent this as a widget on my CMS, or in vBadvance in any way?

Tried all possible ways with PHP Import and stuff...

\\ X

TeknoSounds 05-29-2010 09:16 AM

Quote:

Originally Posted by xabo (Post 2044803)
Hello,

First of all, thanks for a nice hack.

Anyhows im having a question, is there any chance to implent this as a widget on my CMS, or in vBadvance in any way?

Tried all possible ways with PHP Import and stuff...

\\ X

Earlier he mentioned he was going to work on a vBa module. Hopefully he finishes it soon :D Would really love to put it on my portal.

WhatChaMissin 05-31-2010 02:25 PM

1 Attachment(s)
I have a station that broadcast two streams (128kbps and 32kpbs). Would love for there to be a way to include both streams. I only need to have a second set of players with total listeners information for the other stream and not a second "What Playiing"

* I'm willing to pay for this modification, please see attachment

Thanks

raagaswaram 05-31-2010 06:45 PM

Thanks a lot it works gr8 i have installed on my vb 4.0.3 but problem is i couldn't see the song details get refreshed auto.can u tell me how to do it?.

Zachariah 05-31-2010 08:41 PM

Quote:

Originally Posted by TeknoSounds (Post 2044993)
Earlier he mentioned he was going to work on a vBa module. Hopefully he finishes it soon :D Would really love to put it on my portal.

Almost done with a VBA block.

Quote:

Originally Posted by WhatChaMissin (Post 2046043)
I have a station that broadcast two streams (128kbps and 32kpbs). Would love for there to be a way to include both streams. I only need to have a second set of players with total listeners information for the other stream and not a second "What Playiing"

* I'm willing to pay for this modification, please see attachment

Thanks

That should not be a problem.

Quote:

Originally Posted by raagaswaram (Post 2046148)
Thanks a lot it works gr8 i have installed on my vb 4.0.3 but problem is i couldn't see the song details get refreshed auto.can u tell me how to do it?.

by default there is a 120 SEC cache setup and updates are on refreash.
- I will work on auto update in new version

TeknoSounds 06-01-2010 01:54 AM

That's awesome Zachariah :D I can't wait.

Also had some recent ideas for some other shoutcast mods. Gonna look into what all it takes to create an addon. :)

Oh and on that two stream request, it looked pretty simple but the main changes would be in the admincp settings to allow settings for multiple streams?
So I was thinking, along the lines of his request, to allow the mod to have set and show stats for multiple stations., would just have to have a different xml file, and then have an option to show the song/track/mix title in case the stream is the same one or different. All that make sense?

Anyway nothing I need, just seemed a logical step of improvement :)

Oh and did you see my Windows7 error? When attempting to use the WMP link from the addon, the window that loads up doesn't show the player, it just keeps showing "Waiting for video" although the stream play fine.

cyberlooser 06-01-2010 06:30 AM

Quote:

Originally Posted by Zachariah (Post 2046210)
Almost done with a VBA block.

hi Zachariah,

how?

that's your code for the position for the module:

PHP Code:

// Connect to the server
  
switch ($placecast) {
    case 
:
      
$placecast 'forumhome_above_forums';
      break;
    case 
:
      
$placecast 'forumhome_below_forums';
      break;
    case 
:
      
$placecast 'forumhome_wgo_pos1';
      break;
    case 
:
      
$placecast 'forumhome_wgo_pos2';
      break;
    case 
:
      
$placecast 'forumhome_wgo_pos3';
      break;
    case 
:
      
$placecast 'forumhome_wgo_pos4';
      break;
    case 
:
      
$placecast 'forumhome_wgo_pos5';
      break;
    case 
:
      
$placecast '9';
      break;
    default :
      
$placecast 'forumhome_wgo_pos2';
  } 

there is no option for the VGA Block :(
can't find the option 2 select where i want 2 located this Modul.

so i modified your scast.php file a little bit.
in this way it is posible to install as a Modules.

here is the code:

this code should be cleaned up...i'll do this later. while some variables doesn't in use but i forgotten which one was it :D

PHP Code:


<?php
/* -----------------05/28/2010-----------------
This is a Nice hack to add Shoutcast  VBA block Modules on your VB4 Forum Home.
Hope it helps !!!

Original by Zachariah

modified by cyberlooser/h?r


HowTo Install

Install first the Shoutcast Status 3 (VB4) !

1. save this PHP file with this code  as radio.php in your ../forum / modules folder :

2.Create a new PHP module with the following values:
Module Title = "Radio" 
File To Include = radio.php
Identifier = radio


playlist link is implemented 
the playlist link for the players like QT / RP and MediaPlayer need to be reaktivated in this Module


=======================================================
Tested On:

vBulletin 4.0
SHOUTcast Server v1.9.5

=======================================================
*/




$scgroups explode(','$vbulletin->options['scgrp_full']);

//if (is_member_of($vbulletin->userinfo, $scgroups) OR $scgroups[0] == 0) {
//  #####   VBOPTION SETTINGS
  
$scdef $vbulletin->options['scname_full'];
  
$scip $vbulletin->options['scip_full'];
  
$scport $vbulletin->options['scport_full'];
  
$scpass $vbulletin->options['scpass_full'];
  
$file $vbulletin->options['scxml_full'];
  
$cache_tolerance $vbulletin->options['scupdate_full'];
  
$placecast $vbulletin->options['scplace_full'];
  
$scoff $vbulletin->options['scoff_full'];
//  #####   VBOPTION SETTINGS END

$pfad './images/misc/';

// Check if Cache File needs updated or not
  
if (!is_writable($file)) {
    @ 
chmod($folderstring0777);
  }
// Check if Cache needs an update
  
if (file_exists($file)) {
    
clearstatcache();
// filemtime info gets cached so we must ensure that the cache is empty
    
$time_difference time() - filemtime($file);
// echo "$file was last modified: " . date ("F d Y H:i:s.", filemtime($file)) . "( " . $time_difference . " seconds ago) <br>" . "The cache is set to update every " . $cache_tolerance . " seconds.<br>";
  
}
  else {
    
$time_difference $cache_tolerance;
// force update
  
}

// Parses shoutcasts xml to make an effective stats thing for any website
  
$scfp = @ fsockopen($scip$scport$errno$errstr2);


// If server is off line
  
if (!$scfp) {
    if (
$scoff == 1) {

    
echo
"
<html>

<head>
<title>
$scdef</title>
</head>

<body >
 
 <table width=100%>
        <tr>
        <td>
        <img border=0 src=
$pfad/shoutcast_off.gif alt=''> 
        <br><b>
$scdef ist derzeit leider</b></br>
        <img src= 
$pfad/offline.gif />
        </td>
<tr><td colspan=2>Sorry, but at moment the radio is offline. </td></tr>
  </tr>
</table>
</body>
</html>
 "
;
    }
  }
  else {
  
    
// ############ Shoutcast server is online #######################
    
    
if ($time_difference >= $cache_tolerance) {
// update the cache if need be
// Get XML feed from server
      
if ($scsuccs != 1) {
        if (
$scpass) {
          
fputs($scfp"GET /admin.cgi?pass=$scpass&mode=viewxml HTTP/1.0\r\nUser-Agent: SHOUTcast Song Status (Mozilla Compatible)\r\n\r\n");
        }
        else {
          
fputs($scfp"GET /7.html HTTP/1.0\r\nUser-Agent: XML Getter (Mozilla Compatible)\r\n\r\n");
        }
        while (!
feof($scfp)) {
          
$xmlfeed .= fgets($scfp8192);
        }
        
fclose($scfp);
      }
// Output to cache file
      
$tmpfile fopen($file"w+");
      
$fp fwrite($tmpfile$xmlfeed);
      
fclose($tmpfile);
      
flush();
// Outputs the cached file after new data
      
$xmlcache fopen($file"r");
      
$page '';
      if (
$xmlcache) {
        while (!
feof($xmlcache)) {
          
$page .= fread($xmlcache8192);
        }
        
fclose($xmlcache);
      }
    }
    else {
// outputs the cached file
      
$xmlcache fopen($file"r");
      
$page '';
      if (
$xmlcache) {
        while (!
feof($xmlcache)) {
          
$page .= fread($xmlcache8192);
        }
        
fclose($xmlcache);
      }
    }
  }
  if (
$scpass) {
    
// ######### There is a Admin password ###############
    
//define  xml elements
    
$loop = array("AVERAGETIME""CURRENTLISTENERS""PEAKLISTENERS""MAXLISTENERS""SERVERGENRE""SERVERURL""SERVERTITLE""SONGTITLE""SONGURL""WEBHITS""STREAMHITS""LISTEN""STREAMSTATUS""BITRATE""CONTENT");
    
$y 0;
    while (
$loop[$y] != '') {
      
$pageed ereg_replace(".*<$loop[$y]>"""$page);
      
$scphp strtolower($loop[$y]);
      $
$scphp ereg_replace("</$loop[$y]>.*"""$pageed);
      if (
$loop[$y] == SERVERGENRE || $loop[$y] == SERVERTITLE || $loop[$y] == SONGTITLE || $loop[$y] == SERVERTITLE)
        $
$scphp urldecode($$scphp);
      ;
      
$y++;
    }
//get song info and history
    
$pageed ereg_replace(".*<SONGHISTORY>"""$page);
    
$pageed ereg_replace("<SONGHISTORY>.*"""$pageed);
    
$songatime explode("<SONG>"$pageed);
    
$r 1;
    while (
$songatime[$r] != "") {
      
$t $r 1;
      
$playedat[$t] = ereg_replace(".*<PLAYEDAT>"""$songatime[$r]);
      
$playedat[$t] = ereg_replace("</PLAYEDAT>.*"""$playedat[$t]);
      
$song[$t] = ereg_replace(".*<TITLE>"""$songatime[$r]);
      
$song[$t] = ereg_replace("</TITLE>.*"""$song[$t]);
      
$song[$t] = urldecode($song[$t]);
      
$dj[$t] = ereg_replace(".*<SERVERTITLE>"""$page);
      
$dj[$t] = ereg_replace("</SERVERTITLE>.*"""$pageed);
      
$r++;
    }
    
$averagemin "";
    
$hours intval(intval($averagetime) / 3600);
    
$averagemin .= ($padHours) ? str_pad($hours2"0"STR_PAD_LEFT) : $hours 'h&nbsp;';
    
$minutes intval(($averagetime 60) % 60);
    
$averagemin .= str_pad($minutes2"0"STR_PAD_LEFT) . 'm&nbsp;';
    
$seconds intval($averagetime 60) . 's';
    
$averagemin .= str_pad($seconds2"0"STR_PAD_LEFT);
  }
  else {
    
// ######### There is no Admin password ###############
//define all the variables to get (delte any ones you don't want)
    
$page ereg_replace(".*<body>"""$page);
//extract data
    
$page ereg_replace("</body>.*"","$page);
//extract data
    
$numbers explode(","$page);
//extract data
    
$currentlisteners $numbers[0];
    
$streamstatus $numbers[1];
    
$peaklisteners $numbers[2];
    
$maxlisteners $numbers[3];
    
$currentlisteners $numbers[4];
    
$bitrate $numbers[5];
    
$song[0] = $numbers[6];
  }

  
// ######### Create links and media player pages ########
  // ######################################################
  
$listenamp 'http://' $scip ':' $scport '/listen.pls';
  
$listenlnk 'http://' $scip ':' $scport '/listen.pls';

// Player template requests

  
// Server is online display stats
  
if ($scfp) {
    if (
$streamstatus == "1") {
    
      echo 
"

<html>

<head>
<title>
$scdef</title>
</head>

<body>
  <table width=100%>
   <tr>    
    <td><img src=
$pfad/radio.gif align=middle></td>
   
   </tr>
   <tr>
     <td>
     <a href=
$listenamp><b>$scdef <br>
     Server is </b></a>
     <a href=
$listenamp></a>
     </td>
   </tr>
   
   <tr>
    <td colspan=2 ><marquee width=98% scrolldelay=100 scrollamount=5>
     <img src=
$pfad/radio.gif align=middle> <b>$song[0] @ $scdef</b> <img src=$pfad/im_genre.gif align=middle></marquee><br></td>
     </tr>
     <tr>
     <td><marquee width=98% scrolldelay=100 scrollamount=5><b>DJ: 
$servertitle </b> </marquee></td>
     </tr>
    <tr> 
    <td><marquee width=98% scrolldelay=100 scrollamount=5>
      <b>Current Listeners 
$currentlisteners / $maxlisteners </b>
    <b>Bitrate @ 
$bitrate kbps </b> </marquee> </td>
  </tr>
 
</table> 
<table width=100%>
  <tr>
    <td><center><a href=
$listenamp><img src=$pfad/im_qt.gif align=middle> </a></center></td>
    <td><center><a href=
$listenamp><img src=$pfad/im_real.gif align=middle> </a></center></td>
    <td><center><a href=
$listenamp><img src=$pfad/im_winamp.gif align=middle> </a> </center> </td>
    <td><center><a href=
$listenamp><img src=$pfad/im_winmp.gif align=middle> </a></center></td>
  </tr>
</table>
 
</body>
</html>"
;

  }
      
//if ($scoff == 1) 
      
else
      {        
         echo
"
<html>

<head>
<title>
$scdef</title>
</head>

<body >
 
 <table width=100%>
        <tr>
        <td>
        <img border=0 src=
$pfad/shoutcast_off.gif alt=''> 
        <br><b>
$scdef ist derzeit leider</b></br>
        <img src= 
$pfad/offline.gif />
        </td>
<tr><td colspan=2>Sorry, but at moment the radio is offline</td></tr>
  </tr>
</table>
</body>
</html>"
;
      }
    
  }
  
  
  
//}
?>



feel free in use and modify how u like...

RedDevil 06-04-2010 02:49 AM

would like to klnow if anyone is planning to make a vba module for this would be great on portal, of know of one already done, not found one if there is.

Nice work :up:

TeknoSounds 06-04-2010 03:22 AM

Just look at the previous page :) Zachariah is almost finished with his vBa module

RedDevil 06-04-2010 03:32 AM

Im bad thanks just read :)

Lancelance 06-07-2010 07:50 AM

Does this work on 4.0.3?

Zachariah 06-07-2010 10:54 AM

Quote:

Originally Posted by Lancelance (Post 2049786)
Does this work on 4.0.3?

Yes :)

Goodfather 06-25-2010 08:13 AM

How to insert radio to the portal as a CMS item?
Please Help


Does this work on 4.0.4 :)

Gero50 07-02-2010 08:03 PM

Tagged for latter use.

Gold Phan7om 07-14-2010 02:13 PM

Doesnt work on 4.0.4PL1 for me. I put in shoutcast details, connect in and it says its offline on forum..

red.death 07-14-2010 07:17 PM

Only problem with this is that the stats dont auto refresh, you need to refresh whole site to view new stats for the radio.

maidos 07-15-2010 02:00 PM

any news about icecast :/

Gold Phan7om 07-16-2010 03:07 PM

The developer needs to fix it. The addon dosent even work, it doesnt pick up the shoutcast server on 4.0.5

Zachariah 07-16-2010 10:23 PM

Quote:

Originally Posted by Gold Phan7om (Post 2070144)
The developer needs to fix it. The addon dosent even work, it doesnt pick up the shoutcast server on 4.0.5

Haven't looked @ 4.0.5 yet.

Magz 07-16-2010 10:30 PM

working fine on 4.05 here.


All times are GMT. The time now is 01:51 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02952 seconds
  • Memory Usage 1,936KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (15)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete