Playlist, My music wont play please help me |
Playlist, My music wont play please help me |
![]()
Post
#1
|
|
Member ![]() ![]() Group: Member Posts: 14 Joined: Mar 2005 Member No: 120,083 ![]() |
here is my playlist code with the songs and urls unfortunately it wont play do you see something wrong with it. if so can u fix it. i really need this to work
[/CODEBOX]<!-- begin code provided by createblog.com --> <OBJECT ID="Player" height="0" width="0" CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6"> <PARAM NAME="uiMode" VALUE="invisible"> <PARAM NAME="Autostart" VALUE="False"> </object> <FORM ID="form"> <SELECT ID="playlist" size="1"> <!-- Add song info that appears in drop down list here --> <option value="0">98 degrees-the hardest thing</option> <option value="1">wayne wonder-friend like me</option> <option value="2">backsreet boys-all i have to give</option> <option value="3">kelly clarkson-behind these hazel eyes</option> <option value="4">Buju Banton-untold stories</option> <option value="5">case-missing you</option> <option value="6">ashanti and ja rule-down 4 u</option> <option value="7">donnell jones-where i wanna b</option> <option value="8">Roger-i want to be ur man</option> <option value="9">shakira-La tortura</option> <option value="10">50 cent-get in my car</option> <option value="11">50 cent-so amazing</option> <option value="12">backstreet boys-as long as you love me</option> <option value="13">bow wow-let me hold you</option> <option value="14">britney spears-lucky</option> <option value="15">good charlotte-girls and boys</option> <option Value="16">jojo-homeboii</option> <option Value="17">lil jon-get low</option> <option value="18">mariah carey-always be muh baby</option> <option value="19">monica-b4 u walk outa muh lyf</option> <option value="20">Selena-if i could fall in love</option> <option value="21">slum village-selfish</option> <option value="22">snoop dogg-signs</option> <option value="23">tony yayo-so seductive</option> <option value="24">Vitamin c-graduation</option> <option value="25">Corey-The First Time</option> <option value="26">Corey-hush lil lady</option> </SELECT> <BR> <BUTTON ID="BackButton" onClick="Back(forms['form'].playlist);"> << </BUTTON> <BUTTON ID="PlayPauseButton" onClick="PlayPause(forms['form'].playlist);"><FONT color="green"> Play </FONT></BUTTON> <BUTTON ID="NextButton" onClick="Next(forms['form'].playlist);"> >> </BUTTON> <BUTTON ID="StopButton" onclick="Stop();"><FONT color="maroon">Stop</FONT></BUTTON> <b><font size="3" color="black">Shuffle</font></b><INPUT TYPE=checkbox CHECKED ID="ShuffleSwitch" onclick="ToggleShuffle(this);" value="ON"> </FORM> </CENTER> <comment ID="PlayHTML"><FONT color="green"> Play </FONT></comment> <comment ID="ShuffleOnHTML"><INPUT TYPE=checkbox CHECKED ID="ShuffleSwitch" onclick="ToggleShuffle(this);"></comment> <comment ID="ShuffleOffHTML"><INPUT TYPE=checkbox UNCHECKED ID="ShuffleSwitch" onclick="ToggleShuffle(this);"></comment> <script ID="Main" Language="JavaScript"> var songs = new Array(); //*******************************// //****** CHANGEABLE STUFF *******// //*******************************// var shuffle = false; // false = shuffle off, true = shuffle on var autoStart = true; // false = autoStart off, true = autoStart on var numberTracks = true; // true = place track number in front of list items, false = no track numbers // Add song URLs here (make sure it matches up with the order you have for song info, and urls need quotes): songs[0]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/5/4484/25529_1_3_05.asf"; songs[1]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/3/12659/27357_1_4_05.asf"; songs[2]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/5/284/24323_1_6_05.asf"; songs[3]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/2/23893/30200_1_3_05.asf"; songs[4]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/0/4869/6504_1_5_05.asf"; songs[5]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/2/3629/20072_1_1_05.asf"; songs[6]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/0/23005/26040_1_3_05.asf"; songs[7]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/0/7986/9918_1_3_05.asf"; songs[8]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/2/12152/14012_1_11_05.asf"; songs[9]="http://www.blogupload.com/18435/Shakira_feat._Alejandro_Sanz_-_La_Tortura.wma"; songs[10]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/4/9052/30532_1_9_04.asf"; songs[11]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/4/9052/30532_1_20_04.asf"; songs[12]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/5/284/24323_1_3_04.asf"; songs[13]="http://www.sonymusic.com/clips/selection/fu/055671/055671_01_01_full_56.asx"; songs[14]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/2/3087/14042_1_7_04.asf"; songs[15]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/1/15873/27331_1_6_04.asf"; songs[16]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/4/25873/29488_1_5_04.asf"; songs[17]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/0/7706/28104_1_19_04.asf"; songs[18]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/3/293/24603_2_2_04.asf"; Songs[19]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/2/906/2138_1_11_04.asf"; songs[20]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/4/5143/244_1_9_04.asf": songs[21]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/0/1387/29550_1_7_04.asf"; songs[22]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/0/1387/29550_1_7_04.asf"; songs[23]="http://stream.allhiphop.com/02-tony_yayo_50_centso_seduc.ram"; Songs[24]="http://www.wjcc.k12.va.us/djm/teachers/polly/Graduation.mp3"; Songs[25]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/4/22878/25678_1_7_05.asf"; songs[26]="http://a425.v8384d.c8384.g.vm.akamaistream.net/7/426/8384/3b858b51/mtvrdstr.download.akamai.com/8512/wmp/4/22878/25678_1_7_05.asf"; //*******************************// //*******************************// // Initializations // with (document){ var length = forms['form'].playlist.length; if(numberTracks){ for (var i = 0; i < length; i++){ forms['form'].playlist.options[i].innerHTML = (i+1) + " - " + forms['form'].playlist.options[i].innerHTML; } } if (shuffle) { var randsg = Math.floor(Math.random()*songs.length); Player.url = songs[randsg]; forms['form'].playlist.options[randsg].selected = true; forms['form'].ShuffleSwitch.outerHTML = ShuffleOnHTML.innerHTML; } else { forms['form'].ShuffleSwitch.outerHTML = ShuffleOffHTML.innerHTML; Player.url = songs[0]; } if(autoStart){ var snum = forms['form'].playlist.selectedIndex; if(Player.url != songs[snum]){ Player.url = songs[snum]; } Player.controls.Play(); } } // Functions // // Discription: "PlayPause" will toggle playing and pausing if the same song is still selected, // otherwise it will load the newly selected song function PlayPause(list) { var snum = list.selectedIndex; if((Player.url == songs[snum] && Player.url != "") && Player.playState != 1){ if(Player.playState == 3){ Player.controls.Pause(); } else { Player.controls.Play(); } } else { Player.url = songs[snum]; Player.controls.Play(); } } // Discription: "Next" will move to the next music file if shuffle is off // otherwise it will load a random song. Calls PlayPause to start music. function Next(list) { var snum = list.selectedIndex; if (!shuffle) { if (snum == list.length-1) { snum = -1; } snum++; } else { var temp; do{ temp = Math.floor(Math.random()*songs.length); } while(temp == snum); snum = temp; } list.options[snum].selected = true; PlayPause(list); } // Discription: "Back" does the same thing as "Next" but moves backwads // through the list. If shuffle is on then picks a random song. function Back(list) { var snum = list.selectedIndex; if (!shuffle) { if (snum == 0){ snum = list.length; } snum--; } else { var temp; do{ temp = Math.floor(Math.random()*songs.length); } while(temp == snum); snum = temp; } list.options[snum].selected = true; PlayPause(list); } // Discription: Self explanitory. function Stop(){ Player.controls.Stop(); } // Discription: Makes the shuffle flag the same as the status of the CheckBox // The status of the checkbox (true/false) indicates if the box is checked function ToggleShuffle(CheckBox) { shuffle = CheckBox.status; } </SCRIPT> <script ID="StateChangeHandler" Language = "JavaScript" For = "Player" Event = playStateChange(NewState)> // Description: This is an interupt handler used to handle instances when the // state of the player changes to play or stop for example. //STATE.innerText = NewState; switch(NewState){ case 8: // Handles player after it just finishes playing through a song var num = document.forms['form'].playlist.selectedIndex; if (!shuffle){ if(num == document.forms['form'].playlist.length-1){ num = -1; } num++; } else { var temp; do{ temp = Math.floor(Math.random()*songs.length); } while(temp == num); num = temp; } document.forms['form'].playlist.options[num].selected = true; PreviousState = NewState; break; case 1: // Handles player after it stops if(PreviousState == 8){ var num = document.forms['form'].playlist.selectedIndex; Player.settings.autoStart = true; Player.url = songs[num]; PreviousState = NewState; } else if (PreviousState != 3 && PreviousState != 2){ Player.controls.Play(); Player.settings.autoStart = false; } else{ forms['form'].PlayPauseButton.innerHTML = PlayHTML.innerHTML; } break; case 3: // Handles player after it starts to play PreviousState = NewState; forms['form'].PlayPauseButton.innerHTML = "Pause"; shuffle = document.forms['form'].ShuffleSwitch.status; break; case 2: // Handles player after being paused PreviousState = NewState; forms['form'].PlayPauseButton.innerHTML = PlayHTML.innerHTML; break; default: } </SCRIPT> <!-- end code provided by createblog.com -->[CODEBOX] |
|
|
![]() ![]() |