Update of /cvsroot/sageplugins/webserver/webserver/webroot/sage
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12970/webserver/webroot/sage
Modified Files:
player_wmp.html player.html about.html player_other_vlc.html
player_ie_vlc.html player.js menu_items.js
Added Files:
icon_wmp.gif icon_qt.gif icon_vlc.gif player_qt.html
Removed Files:
player_wmp_ax.html
Log Message:
2.0 -- jump to options
Index: player_wmp.html
===================================================================
RCS file: /cvsroot/sageplugins/webserver/webserver/webroot/sage/player_wmp.html,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** player_wmp.html 4 Dec 2005 22:01:21 -0000 1.4
--- player_wmp.html 6 Dec 2005 10:24:31 -0000 1.5
***************
*** 10,19 ****
<SCRIPT LANGUAGE = "JavaScript">
! // parse url into associated array
! var url = CreateUrlObjectMap();
var clipurl;
if ( url.mediafileid != null ) {
! clipurl=MakeMediaFilePlaylist(url.mediafileid,"wvx");
} else if ( url.clipurl ) {
clipurl=MakeURLPlaylist(MakeAbsoluteURL(url.clipurl),"wvx");
--- 10,22 ----
<SCRIPT LANGUAGE = "JavaScript">
!
! var fntype="url"
! if ( url.fntype != null ) {
! fntype=url.fntype;
! }
var clipurl;
if ( url.mediafileid != null ) {
! clipurl=MakeMediaFilePlaylist(url.mediafileid,"wvx",fntype);
} else if ( url.clipurl ) {
clipurl=MakeURLPlaylist(MakeAbsoluteURL(url.clipurl),"wvx");
***************
*** 37,62 ****
//document.write('<p>Playing '+clipurl+'</p>');
with (document) {
! writeln('<EMBED TYPE="application/x-mplayer2"');
! writeln(' PLUGINSPAGE="http://microsoft.com/windows/mediaplayer/en/download/"');
! writeln(' ID=mediaPlayer');
! writeln(' animationAtStart=1');
! writeln(' NAME="mediaPlayer"');
! writeln(' DISPLAYSIZE="0"');// Fit To Size
! writeln(' AUTOSIZE="false"');
! writeln(' BGCOLOR="darkblue"');
! writeln(' SHOWCONTROLS="-1" ');
! writeln(' SHOWTRACKER="-1"');
! writeln(' SHOWDISPLAY="-1"');
! writeln(' SHOWSTATUSBAR="-1"');
! writeln(' AUTOSTART="-1"');
! writeln(' WIDTH=640');
! writeln(' HEIGHT=480');
! writeln(' SRC="'+clipurl+'"');
! writeln(' AUTOSTART="-1" ');
! writeln(' DESIGNTIMESP="5311"');
! writeln(' >');
! writeln('</EMBED><P>');
}
}
! </script></div></body></html>
\ No newline at end of file
--- 40,80 ----
//document.write('<p>Playing '+clipurl+'</p>');
with (document) {
! writeln('<OBJECT ID="MediaPlayer1" ');
! writeln(' CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6" ');
! writeln(' CODEBASE="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab# Version=5,1,52,701" ');
! writeln(' STANDBY="Loading Microsoft Windows Media Player components..." ');
! writeln(' TYPE="application/x-oleobject" ');
! writeln(' width="640" ');
! writeln(' height="480">');
! writeln(' <param name="url" value="'+clipurl+'">');
! writeln(' <param name="uiMode" value="full">');
! writeln(' <param name="animationatStart" value="true">');
! writeln(' <param name="transparentatStart" value="true">');
! writeln(' <param name="autoStart" value="true">');
! writeln(' <param name="showControls" value="true">');
! writeln(' <param name="showStatusBar" value="true">')
! writeln(' <param name="showTracker" value="true">');
! writeln(' <param name="showDisplay" value="true">');
! writeln(' <param name="Volume" value="-300">');
! writeln('<embed type="application/x-mplayer2" ');
! writeln(' pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" ');
! writeln(' src="'+clipurl+'" ');
! writeln(' name="MediaPlayer1" ');
! writeln(' width="640" ');
! writeln(' height="480"');
! writeln(' autostart="true" ');
! writeln(' animationatStart="1"');
! writeln(' showcontrols="1"');
! writeln(' showtracker="1"');
! writeln(' showdisplay="1"');
! writeln(' showstatusbar="1"');
! writeln(' displaysize="0"');
! writeln(' autosize="0"');
! writeln(' bgcolor="darkblue"');
! writeln(' volume=-300></embed>');
! writeln('</OBJECT>');
! writeln('<p align="center"><a href="'+clipurl+'">Open in external media player</a></p>')
}
}
! </script></div></body></html>
--- NEW FILE: icon_wmp.gif ---
(This appears to be a binary file; contents omitted.)
Index: player.html
===================================================================
RCS file: /cvsroot/sageplugins/webserver/webserver/webroot/sage/player.html,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** player.html 4 Dec 2005 22:01:21 -0000 1.4
--- player.html 6 Dec 2005 10:24:31 -0000 1.5
***************
*** 15,81 ****
<SCRIPT LANGUAGE = "JavaScript">
<!--
-
//==============================================================================
! // Browser Detect
//==============================================================================
- var detect = navigator.userAgent.toLowerCase();
- var OS,browser,version,total,thestring;
! if (checkIt('konqueror'))
! {
! browser = "Konqueror";
! OS = "Linux";
! }
! else if (checkIt('safari')) browser = "Safari"
! else if (checkIt('omniweb')) browser = "OmniWeb"
! else if (checkIt('opera')) browser = "Opera"
! else if (checkIt('webtv')) browser = "WebTV";
! else if (checkIt('icab')) browser = "iCab"
! else if (checkIt('msie')) browser = "Internet Explorer"
! else if (!checkIt('compatible'))
! {
! browser = "Netscape Navigator"
! version = detect.charAt(8);
! }
! else browser = "An unknown browser";
! if (!version) version = detect.charAt(place + thestring.length);
- if (!OS)
- {
- if (checkIt('linux')) OS = "Linux";
- else if (checkIt('x11')) OS = "Unix";
- else if (checkIt('mac')) OS = "Mac"
- else if (checkIt('win')) OS = "Windows"
- else OS = "an unknown operating system";
- }
! function checkIt(string)
! {
! place = detect.indexOf(string) + 1;
! thestring = string;
! return place;
}
- //alert(browser+version);
-
- var url=CreateUrlObjectMap();
-
-
//==============================================================================
- // try to determine file type....
- //==============================================================================
- var filetype;
- // first use filename hint
- if ( url.filename && url.filename.lastIndexOf(".") >0 ) {
- var fileext=url.filename.substring(url.filename.lastIndexOf(".")+1,url.filename.length).toLowerCase();
- } else if ( url.clipurl ) {
- // look for a filename in clipurl
- if ( url.clipurl.toLowerCase().match("\.[a-z0-9]+$") ) {
- fileext=url.clipurl.substring(url.clipurl.lastIndexOf(".")+1,url.clipurl.length).toLowerCase();
- }
- }
- //==============================================================================
// Detect available players on non-IE browsers
//==============================================================================
--- 15,89 ----
<SCRIPT LANGUAGE = "JavaScript">
<!--
//==============================================================================
! // Define known media players
//==============================================================================
! var players= {
! 'WMP': {
! 'key' : 'WMP',
! 'name': 'Windows Media Player',
! 'comment': null,
! 'url': 'player_wmp.html',
! 'browserurl': null,
! 'icon': 'icon_wmp.gif'
! },
! 'VLC' : {
! 'key' : 'VLC',
! 'name': 'VideoLan Client',
! 'comment': 'Works best in IE,<br/>Ok in Mozilla<br/>badly or not at all in Opera<br/>untested elsewhere',
! 'ieurl': 'player_ie_vlc.html',
! 'url': 'player_other_vlc.html',
! 'browserurl': {
! 'Internet Explorer' : 'player_ie_vlc.html'
! },
! 'icon': 'icon_vlc.gif'
! },
! // 'REAL' : {
! // 'key' : 'REAL',
! // 'name': 'Real Player',
! // 'comment': '',
! // 'url': ???
! // },
! 'QT' : {
! 'key' : 'QT',
! 'name': 'QuickTime',
! 'comment': '',
! 'url': 'player_qt.html',
! 'browserurl': null,
! 'icon': 'icon_qt.gif'
! }
! };
! //==============================================================================
! // define known file types and media player handlers
! // define which can handle streaming (URL) and which can handle direct file access
! //==============================================================================
! var filetypes = { 'url' : {
! 'mp3': [ 'WMP', 'QT', 'VLC' ],
! 'avi': [ 'VLC' ],
! 'mpg': [ 'VLC' ],
! 'wmv': [ 'WMP' ],
! 'wma': [ 'WMP' ]
! },
! 'filepath' : {
! 'mp3': [ 'WMP', 'QT', 'VLC' ],
! 'avi': [ 'WMP', 'VLC' ],
! 'mpg': [ 'WMP', 'VLC' ],
! 'wmv': [ 'WMP' ],
! 'wma': [ 'WMP' ],
! 'dvd': [ 'WMP' ]
! }
! }
!
! //==============================================================================
! var fntype="url"
! if ( url.fntype != null ) {
! fntype=url.fntype;
}
//==============================================================================
// Detect available players on non-IE browsers
//==============================================================================
***************
*** 109,116 ****
playerString+="VLC"+",";
}
- if (currentPlugin.name.substring(0,23)=="Mozilla ActiveX control")
- {
- playerString+="WMP-AX"+",";
- }
}//end for
}//end if
--- 117,120 ----
***************
*** 164,214 ****
// auto forward browser depending on which file type/player
//==============================================================================
if ( url.clipurl || url.mediafileid ) {
! if ( fileext=="mpg" || fileext=="avi" ) {
! // playback with VLC
! if ( playerString.indexOf("VLC") == -1 ){
! // VLC plugin not found.
! document.write("MPG or AVI files can only be streamed to the VideoLanClient web browser plugin.<br/>");
! document.write('Please install the latest <a href="http://www.videolan.org/vlc/">VideoLanClient</a> for your platform<br/>');
! if ( browser != "Internet Explorer" ) {
! document.write('and install the plugin following the <a href="http://www.videolan.org/doc/play-howto/en/ch04.html#id295937">instructions on their web site</a><br/>');
! }
! document.write('and check that browser plugins are enabled<br/>');
! document.write('<p align=center><a href="http://www.videolan.org/vlc" title="Get Videolan"><img src=GetVLC_120.png></a></p>');
! } else {
! if ( browser == "Internet Explorer" ) {
! document.write("Player will start shortly");
! document.location.replace(location.href.replace("player.html","player_ie_vlc.html"));
! } else if ( browser == "Netscape Navigator" ) {
! document.write("Player will start shortly");
! document.location.replace(location.href.replace("player.html","player_other_vlc.html"));
! } else {
! document.write("VLC player support is untested in non-Mozilla browsers.<br/>Controls do not work at all in Opera.<br/>Redirecting in 5 seconds");
! setTimeout('document.location.replace(location.href.replace("player.html","player_other_vlc.html"));',5000);
! }
! }
! } else if ( fileext=="wmv" || fileext=="wma" ) {
! if ( playerString.indexOf("WMP-AX") != -1 ) {
! document.write("Player will start shortly");
! document.location.replace(location.href.replace("player.html","player_wmp_ax.html"));
! } else if ( playerString.indexOf("WMP") != -1 ) {
! document.write("Player will start shortly");
! document.location.replace(location.href.replace("player.html","player_wmp.html"));
! } else {
! document.write("Could not find a Windows Media Player plugin for WMV or WMA files -- please check that plugins are enabled in your browser<br/>");
! }
! } else {
! // other file types.. assume WMP for the moment
! if ( playerString.indexOf("WMP-AX") != -1 ) {
! document.write("Player will start shortly");
! document.location.replace(location.href.replace("player.html","player_wmp_ax.html"));
! } else if ( playerString.indexOf("WMP") != -1 ) {
! document.write("Player will start shortly");
! document.location.replace(location.href.replace("player.html","player_wmp.html"));
! } else {
! document.write("Could not find a Windows Media Player plugin -- other media player plugins not yet supported<br/>");
! }
! }
} else {
document.write("no 'clipurl' or 'MediaFileId' argument in URL");
--- 168,287 ----
// auto forward browser depending on which file type/player
//==============================================================================
+
+ function PrintPlayerSelector(installedplayers) {
+ document.writeln('<p align="center">Please select media player:<br/>');
+ document.writeln('<input type="checkbox" id="remember">Remember this choice</input></p>');
+ document.writeln('<table align="center"><tr>');
+ for ( k=0; k< installedplayers.length; k++ ) {
+ thisplayer=installedplayers[k];
+ document.writeln('<td align="center" valign="top">');
+ document.writeln('<a href="javascript:DoPlay(\''+thisplayer.key+'\')">');
+ document.writeln(HtmlIze(thisplayer.name)+"<br/>")
+ if ( thisplayer.icon ) {
+ document.writeln('<img src="'+thisplayer.icon+'"/><br/>');
+ }
+ document.writeln("</a>");
+ if ( thisplayer.comment ) {
+ document.writeln(thisplayer.comment);
+ }
+ document.writeln("</td>");
+ }
+ document.writeln("</tr></table>");
+ }
+ function DoPlay(key) {
+ cb=document.getElementById("remember")
+ if ( cb && cb.checked ) {
+ defaultPlayers[fileext]=key;
+ SetDefaultPlayers();
+ }
+ if ( players[key].browserurl != null
+ && players[key].browserurl[browser] != null ) {
+ document.location=location.href.replace("player.html",players[key].browserurl[browser]);
+ } else {
+ document.location=location.href.replace("player.html",players[key].url);
+ }
+ }
+
+ // get list of default players from cookie
+ var defaultPlayers=new Object();
+ cookie=GetCookie("defaultPlayers");
+ if ( cookie ) {
+ list=GetCookie("defaultPlayers").split(",");
+ for(i = 0; i < list.length; i++)
+ {
+ eq = list[i].indexOf('=');
+ defaultPlayers[list[i].substring(0,eq).toLowerCase()] = unescape(list[i].substring(eq + 1));
+ }
+ }
+
+ function SetDefaultPlayers() {
+ cookiestring="";
+ for(key in defaultPlayers) {
+ if ( cookiestring != "" ) {
+ cookiestring=cookiestring+",";
+ }
+ cookiestring=cookiestring+key+"="+defaultPlayers[key];
+ }
+ SetCookie("defaultPlayers",cookiestring);
+ //alert("defaultPlayers="+cookiestring);
+ }
+
if ( url.clipurl || url.mediafileid ) {
!
! playerlist=filetypes[fntype][fileext];
! if ( playerlist ) {
! // check for installed players
! j=0;
! installedplayers=[];
! for ( i=0; i< playerlist.length; i++ ) {
! if ( playerString.indexOf(playerlist[i]) != -1
! && players[playerlist[i]] != null ) {
! installedplayers[j]=players[playerlist[i]];
! j++
! }
! }
! if ( installedplayers.length == 0 ) {
! document.write("<p align='center'>You do not have any installed players that can play back "+fileext+" files</p>");
! document.write("<p align='center'>Supported players are: <br/>");
! for ( i=0; i< playerlist.length ; i ++ ) {
! if ( players[playerlist[i]] != null ) {
! document.write(HtmlIze(players.name));
! }
! }
! }
!
! if ( installedplayers.length == 1 ) {
! // only one player -- auto-forward
! document.write("Player will start shortly");
! DoPlay(installedplayers[0].key);
! } else {
! // multiple players -- check cookie
! if ( defaultPlayers[fileext] != null ) {
! DoPlay(defaultPlayers[fileext]);
! } else {
! document.write("<p align='center'>Multiple players can play back "+fileext+" files</p>");
! PrintPlayerSelector(installedplayers);
! }
! }
! } else {
! //unknown filetype -- check cookie
! if ( defaultPlayers[fileext] != null ) {
! DoPlay(defaultPlayers[fileext]);
! } else {
! document.write("<p align='center'>I dont known which player can play back "+fileext+" files</p>");
! // suggest all installed players
! j=0;
! installedplayers=new Array();
! for ( playerkey in players ) {
! //alert(playerkey);
! if ( playerString.indexOf(playerkey) != null ) {
! installedplayers[j]=players[playerkey];
! j++;
! }
! }
! PrintPlayerSelector(installedplayers);
! }
! }
} else {
document.write("no 'clipurl' or 'MediaFileId' argument in URL");
Index: menu_items.js
===================================================================
RCS file: /cvsroot/sageplugins/webserver/webserver/webroot/sage/menu_items.js,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** menu_items.js 3 Dec 2005 01:01:53 -0000 1.3
--- menu_items.js 6 Dec 2005 10:24:31 -0000 1.4
***************
*** 168,172 ****
[
'Watched Shows',
! 'Search?SearchString=&searchType=Airings&TimeRange=-999&watched=set&sort1=title_asc&sort2=airdate_asc',
{
'title' :'Search the Sage DB for all shows that have been marked as watched'
--- 168,172 ----
[
'Watched Shows',
! 'Search?SearchString=&searchType=Airings&TimeRange=-999&watched=set&sort1=airdate_desc&sort2=none',
{
'title' :'Search the Sage DB for all shows that have been marked as watched'
***************
*** 203,207 ****
[
'Search Music by track Title',
! 'Search?searchType=MediaFiles&Music=on&search_fields=episode&sort1=title_asc&sort2=none',
{
'title' :'Search the Media Library for Music Files matching the track title'
--- 203,207 ----
[
'Search Music by track Title',
! 'Search?searchType=MediaFiles&Music=on&search_fields=episode&sort1=episode_asc&sort2=none',
{
'title' :'Search the Media Library for Music Files matching the track title'
***************
*** 210,214 ****
[
'Search Music by Artist',
! 'Search?searchType=MediaFiles&Music=on&search_fields=people&sort1=people_asc&sort2=title_asc',
{
'title' :'Search the Media Library for Music Files matching the Artist Name'
--- 210,214 ----
[
'Search Music by Artist',
! 'Search?searchType=MediaFiles&Music=on&search_fields=people&sort1=people_asc&sort2=episode_asc',
{
'title' :'Search the Media Library for Music Files matching the Artist Name'
***************
*** 217,221 ****
[
'Search Music by Album',
! 'Search?searchType=MediaFiles&Music=on&search_fields=title&sort1=people_asc&sort2=title_asc',
{
'title' :'Search the Media Library for Music Files matching the Album Name'
--- 217,221 ----
[
'Search Music by Album',
! 'Search?searchType=MediaFiles&Music=on&search_fields=title&sort1=title_asc&sort2=episode_asc',
{
'title' :'Search the Media Library for Music Files matching the Album Name'
***************
*** 223,226 ****
--- 223,233 ----
],
[
+ 'Search Music by Genre',
+ 'Search?searchType=MediaFiles&Music=on&search_fields=category&sort1=title_asc&sort2=episode_asc',
+ {
+ 'title' :'Search the Media Library for Music Files matching the Category'
+ }
+ ],
+ [
'Search Picture Files',
'Search?searchType=MediaFiles&Picture=on&sort1=title_asc&sort2=none',
Index: player_ie_vlc.html
===================================================================
RCS file: /cvsroot/sageplugins/webserver/webserver/webroot/sage/player_ie_vlc.html,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** player_ie_vlc.html 4 Dec 2005 22:01:21 -0000 1.4
--- player_ie_vlc.html 6 Dec 2005 10:24:31 -0000 1.5
***************
*** 10,22 ****
<SCRIPT LANGUAGE = "JavaScript">
! var url = CreateUrlObjectMap();
var clipurl;
if ( url.mediafileid != null ) {
! clipurl=MakeMediaFilePlaylist(url.mediafileid,"m3u");
} else if ( url.clipurl ) {
! clipurl=MakeURLPlaylist(MakeAbsoluteURL(url.clipurl),"wvx");
}
-
</SCRIPT>
</HEAD>
--- 10,24 ----
<SCRIPT LANGUAGE = "JavaScript">
! var fntype="url"
! if ( url.fntype != null ) {
! fntype=url.fntype;
! }
var clipurl;
if ( url.mediafileid != null ) {
! clipurl=MakeMediaFilePlaylist(url.mediafileid,"m3u",fntype);
} else if ( url.clipurl ) {
! clipurl=MakeURLPlaylist(MakeAbsoluteURL(url.clipurl),"m3u");
}
</SCRIPT>
</HEAD>
***************
*** 74,86 ****
<INPUT type="button" value="2m FF" onClick="document.vlc.shuttle(120);">
<br/>
! <SCRIPT LANGUAGE="JavaScript">
! // todo playlist next/prev
! //if ( url.numsegments && url.numsegments>1 ){
! // document.writeln('<INPUT type=button id="PrevSegment" value="PrevSegment" onClick="document.vlc.Position=document.vlc.Position-1;">');
! // document.writeln('<INPUT type=button id="NextSegment" value="PrevSegment" onClick="document.vlc.Position=document.vlc.Position+1;">');
! //}
! </script>
</TD></TR>
</TABLE>
<p align=center><a href="http://www.videolan.org/vlc" title="Get Videolan"><img src=GetVLC_120.png></a></p>
</div>
--- 76,85 ----
<INPUT type="button" value="2m FF" onClick="document.vlc.shuttle(120);">
<br/>
! <p>Double-click VLC window to go fullscreen if FullScreen button does not work.</p>
</TD></TR>
</TABLE>
+ <script language="JavaScript">
+ document.writeln('<p align="center"><a href="'+clipurl+'">Open in external media player</a></p>')
+ </script>
<p align=center><a href="http://www.videolan.org/vlc" title="Get Videolan"><img src=GetVLC_120.png></a></p>
</div>
***************
*** 237,239 ****
</div>
</body>
! </html>
\ No newline at end of file
--- 236,238 ----
</div>
</body>
! </html>
--- NEW FILE: icon_qt.gif ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: icon_vlc.gif ---
(This appears to be a binary file; contents omitted.)
--- NEW FILE: player_qt.html ---
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="ltr">
<head>
<link rel="stylesheet" type="text/css" media="all" href="sage_all.css"/>
<link rel="stylesheet" type="text/css" media="print" href="sage_print.css"/>
<link rel="Shortcut Icon" href="/favicon.ico" type="image/x-icon"/>
<script type="text/javascript" src="sage.js"></script>
<script type="text/javascript" src="player.js"></script>
<title>Sage Media Player</title>
<SCRIPT LANGUAGE = "JavaScript">
var fntype="url"
if ( url.fntype != null ) {
fntype=url.fntype;
}
var clipurl;
if ( url.mediafileid != null ) {
clipurl=MakeMediaFilePlaylist(url.mediafileid,"m3u",fntype);
} else if ( url.clipurl ) {
clipurl=MakeURLPlaylist(MakeAbsoluteURL(url.clipurl),"m3u");
}
</SCRIPT>
</HEAD>
<body>
<div id="title">
<h1><a href="Home" title="home"><img src="sagelogo.gif" alt="SageTV logo" title="Home Screen" border="0"/></a>Sage Media Player</h1>
</div>
<div id="content">
<SCRIPT LANGUAGE="JavaScript">
if ( url.title ){
document.write("<p align=center>"+HtmlIze(unescape(url.title))+"</p>");
}
if ( clipurl ) {
//document.write('<p>Playing '+clipurl+'</p>');
with (document) {
writeln('<OBJECT ID="MediaPlayer1" ');
writeln(' CLASSID="CLSID:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" ');
writeln(' CODEBASE="http://www.apple.com/qtactivex/qtplugin.cab" ');
writeln(' STANDBY="Loading QuickTime Player components..." ');
writeln(' TYPE="application/x-oleobject" ');
writeln(' width="640" ');
writeln(' height="480">');
writeln(' <param name="SRC" value="'+clipurl+'">');
writeln(' <param name="AUTOPLAY" value="true">');
writeln(' <param name="CONTROLLER" value="true">');
writeln(' <param name="BGCOLOR" value="darkblue">');
writeln('<embed type="video/quicktime" ');
writeln(' pluginspage="http://www.apple.com/quicktime/download/" ');
writeln(' src="'+clipurl+'" ');
writeln(' name="MediaPlayer1" ');
writeln(' width="640" ');
writeln(' height="480"');
writeln(' AUTOPLAY="true" ');
writeln(' CONTROLLER="true"');
writeln(' bgcolor="darkblue"></embed>');
writeln('</OBJECT>');
writeln('<p align="center"><a href="'+clipurl+'">Open in external media player</a></p>')
}
}
</script></div></body></html>
Index: about.html
===================================================================
RCS file: /cvsroot/sageplugins/webserver/webserver/webroot/sage/about.html,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** about.html 4 Dec 2005 22:18:49 -0000 1.16
--- about.html 6 Dec 2005 10:24:31 -0000 1.17
***************
*** 30,35 ****
<p>The sage Web Server was written by nielm, with hints from various people on the Forums!</p>
! <p>The WebRemote page was written by Wheemer</p>
! <p>Favorites support was written by jreichen</p>
<p>The Menu Bar uses the
--- 30,35 ----
<p>The sage Web Server was written by nielm, with hints from various people on the Forums!</p>
! <p>The WebRemote page was written by <a href="http://forums.sage.tv/forums/member.php?u=3097">Wheemer</a></p>
! <p>Favorites support was written by <a href="http://forums.sage.tv/forums/member.php?u=2152"jreichen</a></p>
<p>The Menu Bar uses the
***************
*** 45,57 ****
<hr>
<h3>Changelog</h3>
! <h4>V2.0 Dec 2 2005</h4>
<pre>
* NEW FEATURE: Favorites Management -- Add/remove/re-priority favorites
Big thanks to jreichen from the Sage Forums for implementing this.
- * BUGFIX: fixed Sage mediafile download so that no password is required
- * BUGFIX: fixed Sage mediafile + webserver normal file download to support HTTP Range requests
- !!! Seeking in streaming files now possible with supported players !!!
- * ENHANCEMENT: included ajuhawk's Sage Encoder support.
- set the property "nielm/webserver/enableSageEncoderOpts=true" to enable
* NEW FEATURE: Web-based media player
Click Watch Now on any recording in the detailed info screen
--- 45,52 ----
<hr>
<h3>Changelog</h3>
! <h4>V2.0 Dec 6 2005</h4>
<pre>
* NEW FEATURE: Favorites Management -- Add/remove/re-priority favorites
Big thanks to jreichen from the Sage Forums for implementing this.
* NEW FEATURE: Web-based media player
Click Watch Now on any recording in the detailed info screen
***************
*** 60,63 ****
--- 55,65 ----
Best results using IE (Sorry. I hate browser-dependant stuff!)
No re-encoding support -- you download the original files...
+ * BUGFIX: fixed Sage mediafile download so that no password is required
+ * BUGFIX: fixed Sage mediafile + webserver normal file download to support HTTP Range requests
+ !!! Seeking in streaming files now possible with supported players !!!
+ * BUGFIX: webremote and about pages now have a menu bar!
+ * BUGFIX: changed TvTome search to TV.com
+ * ENHANCEMENT: included ajuhawk's Sage Encoder support.
+ set the property "nielm/webserver/enableSageEncoderOpts=true" to enable
* ENHANCEMENT: Detailed Information pages now have streaming and file-based playlist links.
This allows one-click access to files in external media players
***************
*** 69,74 ****
* ENHANCEMENT: Fallback main menu for non-Javascript browsers.
* ENHANCEMENT: jump to a channel in EPG views
! * BUGFIX: webremote and about pages now have a menu bar!
! * BUGFIX: changed TvTome search to TV.com
</pre>
--- 71,76 ----
* ENHANCEMENT: Fallback main menu for non-Javascript browsers.
* ENHANCEMENT: jump to a channel in EPG views
! * ENHANCEMENT: jump to options block in Sage recordings on [show options]
!
</pre>
***************
*** 173,177 ****
TODO: CSS refactor (layout/colors)
TODO: viewing history download (output search as XML)
- TODO: Favorite management
TODO: tree-like structure for sage recordings groups
TODO: popup detailed info pages
--- 175,178 ----
Index: player_other_vlc.html
===================================================================
RCS file: /cvsroot/sageplugins/webserver/webserver/webroot/sage/player_other_vlc.html,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** player_other_vlc.html 4 Dec 2005 22:01:21 -0000 1.4
--- player_other_vlc.html 6 Dec 2005 10:24:31 -0000 1.5
***************
*** 10,22 ****
<SCRIPT LANGUAGE = "JavaScript">
! var url = CreateUrlObjectMap();
! var clipurl="";
if ( url.mediafileid != null ) {
! clipurl=MakeMediaFilePlaylist(url.mediafileid,"m3u");
} else if ( url.clipurl ) {
! clipurl=MakeURLPlaylist(MakeAbsoluteURL(url.clipurl),"wvx");
}
-
</SCRIPT>
</HEAD>
--- 10,24 ----
<SCRIPT LANGUAGE = "JavaScript">
! var fntype="url"
! if ( url.fntype != null ) {
! fntype=url.fntype;
! }
! var clipurl;
if ( url.mediafileid != null ) {
! clipurl=MakeMediaFilePlaylist(url.mediafileid,"m3u",fntype);
} else if ( url.clipurl ) {
! clipurl=MakeURLPlaylist(MakeAbsoluteURL(url.clipurl),"m3u");
}
</SCRIPT>
</HEAD>
***************
*** 37,41 ****
document.write(' name="vlc" id="vlc"');
document.write(' autoplay="yes" loop="no" width="640" height="480"');
! document.write(' target="'+clipurl+'" />');
</script>
<br/>
--- 39,43 ----
document.write(' name="vlc" id="vlc"');
document.write(' autoplay="yes" loop="no" width="640" height="480"');
! document.write(' src="'+clipurl+'" />');
</script>
<br/>
***************
*** 63,66 ****
--- 65,75 ----
<INPUT type="button" value="2m FF" onClick="document.vlc.seek(120,1);">
<br/>
+ <p>Double-click VLC window to go fullscreen if FullScreen button does not work.</p>
+ <script language="JavaScript">
+ document.writeln('<p align="center"><a href="'+clipurl+'">Open in external media player</a></p>')
+ if ( browser != "Mozilla" ) {
+ document.write("<p>Warning: VLC plugin does not work very well with non-Mozilla browsers...<br/>Controls do not work at all in Opera!</p>");
+ }
+ </script>
<p align=center><a href="http://www.videolan.org/vlc" title="Get Videolan"><img src=GetVLC_120.png></a></p>
</div>
***************
*** 180,187 ****
sliderTimerId = setTimeout("doUpdate()", 5000);
onPlay();
-
-
//-->
</SCRIPT>
</body>
! </html>
\ No newline at end of file
--- 189,194 ----
sliderTimerId = setTimeout("doUpdate()", 5000);
onPlay();
//-->
</SCRIPT>
</body>
! </html>
--- player_wmp_ax.html DELETED ---
Index: player.js
===================================================================
RCS file: /cvsroot/sageplugins/webserver/webserver/webroot/sage/player.js,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** player.js 4 Dec 2005 22:01:21 -0000 1.1
--- player.js 6 Dec 2005 10:24:31 -0000 1.2
***************
*** 1,19 ****
-
//==============================================================================
// Parse URL into object-map
//==============================================================================
!
! function CreateUrlObjectMap() {
var qs = location.search.substring(1);
var nv = qs.split('&');
- var urlmap = new Object();
for(i = 0; i < nv.length; i++)
{
eq = nv[i].indexOf('=');
! urlmap[nv[i].substring(0,eq).toLowerCase().replace("nol_","")] = unescape(nv[i].substring(eq + 1));
}
- return urlmap;
}
function HtmlIze(text) {
return text.replace(/&/g, "&").replace(/</g,"<").replace(/>/g, ">").replace(/\+/g, " ");
--- 1,32 ----
//==============================================================================
// Parse URL into object-map
//==============================================================================
! var url = new Object();
! {
var qs = location.search.substring(1);
var nv = qs.split('&');
for(i = 0; i < nv.length; i++)
{
eq = nv[i].indexOf('=');
! url[nv[i].substring(0,eq).toLowerCase().replace("nol_","")] = unescape(nv[i].substring(eq + 1));
}
}
+
+ //==============================================================================
+ // try to determine file type....
+ //==============================================================================
+ var fileext="unknown";
+ // first use filename hint
+ if ( url.filename && url.filename.lastIndexOf(".") >0 ) {
+ fileext=url.filename.substring(url.filename.lastIndexOf(".")+1,url.filename.length).toLowerCase();
+ } else if ( url.clipurl ) {
+ // look for a filename in clipurl
+ if ( url.clipurl.toLowerCase().match("\.[a-z0-9]+$") ) {
+ fileext=url.clipurl.substring(url.clipurl.lastIndexOf(".")+1,url.clipurl.length).toLowerCase();
+ }
+ }
+
+
function HtmlIze(text) {
return text.replace(/&/g, "&").replace(/</g,"<").replace(/>/g, ">").replace(/\+/g, " ");
***************
*** 26,34 ****
}
! function MakeMediaFilePlaylist(mediafileid,pltype) {
! return MakeAbsoluteURL("/sagepublic/PlaylistGenerator?Command=Generate&pltype="+pltype+"&fntype=url&MediaFileId="+mediafileid);
}
function MakeURLPlaylist(url,pltype) {
return MakeAbsoluteURL("/sagepublic/PlaylistGenerator?Command=Generate&fntype=url&pltype="+pltype+"&Url="+escape(url));
! }
\ No newline at end of file
--- 39,93 ----
}
! function MakeMediaFilePlaylist(mediafileid,pltype,fntype) {
! return MakeAbsoluteURL("/sagepublic/PlaylistGenerator?Command=Generate&pltype="+pltype+"&fntype="+fntype+"&MediaFileId="+mediafileid);
}
function MakeURLPlaylist(url,pltype) {
return MakeAbsoluteURL("/sagepublic/PlaylistGenerator?Command=Generate&fntype=url&pltype="+pltype+"&Url="+escape(url));
! }
!
!
! //==============================================================================
! // Browser Detect
! //==============================================================================
! var detect = navigator.userAgent.toLowerCase();
! var OS,browser,version,total,thestring;
!
! if (checkIt('konqueror'))
! {
! browser = "Konqueror";
! OS = "Linux";
! }
! else if (checkIt('safari')) browser = "Safari"
! else if (checkIt('omniweb')) browser = "OmniWeb"
! else if (checkIt('opera')) browser = "Opera"
! else if (checkIt('webtv')) browser = "WebTV";
! else if (checkIt('icab')) browser = "iCab"
! else if (checkIt('msie')) browser = "Internet Explorer"
! else if (checkIt('firefox')) browser = "Firefox"
! else if (!checkIt('compatible'))
! {
! browser = "Mozilla"
! version = detect.charAt(8);
! }
! else browser = "An unknown browser";
!
! if (!version) version = detect.charAt(place + thestring.length);
!
! if (!OS)
! {
! if (checkIt('linux')) OS = "Linux";
! else if (checkIt('x11')) OS = "Unix";
! else if (checkIt('mac')) OS = "Mac"
! else if (checkIt('win')) OS = "Windows"
! else OS = "an unknown operating system";
! }
!
! function checkIt(string)
! {
! place = detect.indexOf(string) + 1;
! thestring = string;
! return place;
! }
!
! //alert(browser+version);
\ No newline at end of file
|