// common js code for network
//Clear inherited frames
if (parent != self) {
top.location=self.document.location;
}
//random number for dc
//var ord = Math.round(Math.random() * 10000000000);
var abc = Math.random() + "";
var ord = abc.substring(2,abc.length);
//get stylesheet regardless of browser
//document.write('');
//Shared Functions
// Pop-Up Embedder Script by David Battino, www.batmosphere.com
function PlayerOpen(soundfiledesc,soundfilepath, width, height) {
winPadding = 100;//for the header and caption
if (!width){
winWidth=320;
width =300;
}
else{
winWidth = winPadding + Number(width);
}
if(!height){
winHeight=190;
height = 42;
}
else{
winHeight = winPadding + Number(height);
}
PlayWin = PrivoxyWindowOpen('','Player','width=' + winWidth + ',height=' + winHeight + ',top=0,left=0,resizable=yes,scrollbars=auto,titlebar=yes,toolbar=yes,menubar=yes,status=yes,directories=yes');
PlayWin.focus();
PlayWin.document.write("
" + soundfiledesc + "");
PlayWin.document.write("");
PlayWin.document.write("");
PlayWin.document.write("" + soundfiledesc + "");
PlayWin.document.write("");
PlayWin.document.write("Download this file (right-click or Option-click)
");
PlayWin.document.write("");
PlayWin.document.write("");
PlayWin.document.close(); // "Finalizes" new window
}
// Pop-Up Embedder by David Battino, www.batmosphere.com
function PopImage(filedesc,filepath,origwidth,origheight,caption) {
winPadding = 100;//for the header and caption
winWidth = winPadding + Number(origwidth);
winHeight = winPadding + Number(origheight);
PlayWin = PrivoxyWindowOpen('','Image','width=' + winWidth + ',height=' + winHeight + ',resizable=1,scrollbars=1,titlebar=yes,toolbar=yes,menubar=yes,status=yes,directories=yes');
PlayWin.document.write("" + filedesc + "");
PlayWin.document.write("");
PlayWin.document.write("");
PlayWin.document.write("");
PlayWin.document.write("
" + filedesc + "
");
PlayWin.document.write("
");
PlayWin.document.write("
![" +filedesc + " " + filedesc + "](" + filepath + ")
");
PlayWin.document.write("
" + caption + "
");
PlayWin.document.write("
");
PlayWin.document.write("
");
PlayWin.document.write("");
PlayWin.document.write("");
PlayWin.document.close(); // "Finalizes" new window
}
// JavaScript Document
// Pop-Up Embedder Script by David Battino, www.batmosphere.com
// v 2005-05-02a
function MediaPop(popuptitle,imgpath,imgwidth,imgheight,caption,soundpath,UniqueID) { // CONSIDER ADDING ERROR HANDLING
var winWidth = Number(imgwidth) + 100; // imgwidth should be <651; shoot for 600
var rawHeight = Number(imgheight) + 168 + caption.length/7; // calculate window height based on caption length
var winHeight = Math.round(rawHeight * Math.pow(10,0))/Math.pow(10,0); // round to integer
MediaWin = PrivoxyWindowOpen('',UniqueID,'width=' + winWidth + ',height=' + winHeight + ',top=0,left=0,resizable=1,scrollbars=auto,titlebar=yes,toolbar=yes,menubar=yes,status=yes,directories=yes,personalbar=0');
MediaWin.focus();
var winContent = "" + popuptitle + "";
winContent += "";
winContent += "";
winContent += "";
winContent += "
"; // restrict width
winContent += "
![" + popuptitle + " " + popuptitle + "](" + imgpath + ")
";
winContent += "
";
winContent += "
" + caption + "
";
winContent += "
";
winContent += "
";
winContent += "";
MediaWin.document.write(winContent);
MediaWin.document.close(); // "Finalizes" new window
}