View Single Post
Old 05-20-2005, 07:39 PM   PM User | #84
_Aerospace_Eng_
Supreme Master coder!


 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a place far, far away...
Posts: 19,293
Thanks: 2
Thanked 1,044 Times in 1,020 Posts
_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light
Try this one instead
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script type="text/javascript"><!--
function song(){
document.getElementById('music1').innerHTML="<embed type='application/x-mplayer2' id='music2' pluginspage='http://www.microsoft.com/Windows/MediaPlayer/' src='"+document.getElementById('cancion').value+"' name='MediaPlayer1' width='300' height='75' controltype='2' showcontrols='1' showstatusbar='1' AutoStart='true'></embed>";
}
//-->
</script>
</head>
<body>
<select  id="cancion" onchange="song()" size="1"> 
   <option value="none">::::::::::::: Choose Your Song Here :::::::::::::</option>
   <option value="http://urltosong1.mp3">Song 1</option>
   <option value="http://urltosong2.mp3">Song 2</option>
   <option value="http://urltosong3.mp3">Song 3</option>
   <option value="http://urltosong4.mp3">Song 4</option>
   <option value="http://urltosong5.mp3">Song 5</option>	
</select><br> 
<span id="music1"><embed type="application/x-mplayer2" id="music1"
pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" 
src="" 
name="MediaPlayer1" 
width="300"
height="70"
controltype="2" 
showcontrols="1"
showstatusbar="1"
AutoStart="0">
</embed></span>
</div>
</body>
</html>
Its not as bulky, and it should work in other browsers as well. Also the option values might have to be exact urls or it might not work properly, at least this is what I discovered after testing.
_Aerospace_Eng_ is offline