Server/Code/mainscreen.html
Jump to navigation
Jump to search
<html> <head> <!--Singer: {singer}--> <title>kJams Server</title> <script src="spry/xpath.js"></script> <script src="spry/SpryData.js"></script> <script src="ui.js"></script> <script src="data.js"></script> <script src="main.js"></script> <script src="common.js"></script> <script src="iscroll.js"></script> <script src="blockUnload.js"></script> <script type="text/javascript"> <!-- var allowUnload = false; blinkSpeed=150; tagName="blinker"; blinkerFlag=1; blinkElement=document.getElementsByName(tagName); blinkText(); function blinkText() { if (blinkerFlag== 1) { blinkState="visible"; } else { blinkState="hidden"; } blinkerFlag ^=1; for(i=0;i<blinkElement.length;i++) { blinkElement[i].style.visibility=blinkState; } setTimeout("blinkText()", blinkSpeed); } --> </script> <script type="text/javascript"> //variable to control if message is shown var allowUnload = false; // function triggered by any closing of the current document function confirmUnload(){ if(!allowUnload){ //message displayed (as well as inbuilt IE junk) when page is unloaded. return 'Why on earth would you think it is a good idea to close this window?!? Well, it ISN\'T!!! Do NOT close this window. If you do, all hell will rain down upon you, you will get A.I.D.S., and I will get very upset (at you closing the window, not the A.I.D.S., that\'s on you).\n :\'('; } } //register function with the event handler window.onbeforeunload = confirmUnload; </script> <link rel="stylesheet" href="screen.css" media="screen"/> <link rel="stylesheet" href="handheld.css" media="handheld, only screen and (max-device-width:480px)"/> </head> <body onLoad="m_sessionCheckin()"; "loaded()" onmousemove="m_pingSession()" onclick="m_pingSession()" onkeypress="m_pingSession()" onscroll="m_pingSession()"> <div id="main"> <table><tr><td id="title"><nobr>{singer}</nobr></td><td id="search"><nobr>Search Library: <input type="search" id="searchfield" name="search" onkeypress=searchKeyPressed(event) onblur="inSearch.off()" onfocus="inSearch.on()" /><input type="submit" style="" name="dosearch" value="Go" onclick=m_doSearch() /></nobr></td><td id="help"><nobr>[ <a id="helplink" onClick="allowUnload=true" href="">Help</a> ] [ <a id="logoutlink" onClick="allowUnload=true" href="">Logout</a> ]</nobr></td></tr></table> <div> <div id="left"> <div id="playlists"></div> <div id="photo"><img src="kjams-main.jpg" /></div> </div> <div id="wrapper"> <div id="songs"><p id="msg_error"></p><p id="msg_dosearch">Please enter a search.<br><br><b> Hint: To limit your search to just a particular artist, type "artist:" followed by the name of the artist.<br>Likewise, to search just on song names type "song name:" and then the name of your song, etc..</b></p><p id="message">Please enter a search.<br><br><i>Type your search into the search field above and hit "Go".<br><br>To submit a song, just click the "Tonight" button for that song in the search results. (You can also make your own "Favorties" list.)<br><br>You will be informed at the bottom of the screen when you have successfully submitted a song.</i><br><br><b> Hint: To limit your search to just a particular artist, type "artist:" followed by the name of the artist.<br>Likewise, to search just on song names type "song name:" and then the name of your song, etc..</b></p><p id="waiting">Please wait, loading search results… .<br><i><b>(This may take a while. <span style="color:#FF0000"><a name=blinker>Please do NOT</a> try another search until the first results are returned.)</span></b></i></p></div> </div> <div class="clear"></div> <div id="status">Welcome to kJams!</div> </div> </div> <script language="javascript"> //Bind key press function document.onkeyup = m_keyPressed; //Prevent browser from seeing the Delete key press document.onkeydown=trapDelete; //Hide message fields document.getElementById("waiting").style.display = 'none'; document.getElementById("msg_dosearch").style.display = 'none'; document.getElementById("msg_error").style.display = 'none'; //Plug in help and logout URLs document.getElementById("helplink").href = url_help; document.getElementById("logoutlink").href = url_login; //Playlists m_populatePlaylists(); if (0) { //Song list var songs = new KJList(); songs.create(document.getElementById("songs")); songs.setColumns(Array("#", "Song Name", "Artist", "Pitch", "Add to", "Add to"), 1); //Set clipping songs.setClipping({'right' : songs.getColumnWidth(5) + songs.getColumnWidth(4) + songs.getColumnWidth(3)}); getSongs(url_songs, populateList, 'playlist=1'); function populateList(songList) { for(var i = 0; i < songList.length; i++) { songs.addItem(songList[i]['number'], Array(songList[i]['number'], songList[i]['name'], songList[i]['artist'], "<select><option>+6</option><option>+5</option><option>+4</option><option>+3</option><option>+2</option><option>+1</option><option selected>0</option><option>-1</option><option>-2</option><option>-3</option><option>-4</option><option>-5</option></select>", "<input type=\"submit\" value=\"Tonight\" />", "<input type=\"submit\" value=\"Favorites\" />"), null, null, false); } songs.color(); } } </script> </body> </html>