Location: PHPKode > scripts > Embed Shoutcast radio > embed-shoutcast-radio/xzyradio.php
<?php

class xzyradio { //web embedded radio player
	var $attribs;
	function __construct($src) {
		//$this->attrib('pluginspage','http://www.microsoft.com/Windows/MediaPlayer/');
		//uncomment line above when really needed
		$this->attrib('type','application/x-mplayer2');
		$this->attrib('width','200');
		$this->attrib('height','45');
		$this->attrib('loop','False');
		$this->attrib('autostart','True');
		$this->attrib('showstatusbar','false');
		$this->attrib('volume','30');
		$this->attrib('src',$src);
	}
	
	function attrib($name, $value) {
		$this->attribs[$name] = $value;
	}
	
	function __toString() {
		foreach($this->attribs as $name => $value) {
			$tmp .= " $name='$value'";
		}
		return "<embed$tmp></embed>";
	}
}

?>
Return current item: Embed Shoutcast radio