function checkFramed() {
hst = "";
pge = "";
qst = "";
hst = document.location.hostname;
pge = parent.location.pathname.substring(1,100);
qst = parent.location.search.substring(1,100);
if ((pge != "") && (pge != "~jazzmo2/JazzMo/test.html") && (qst == ""))
{parent.location.href = ("http://" + hst +"?" + pge)}
}

function popUp(URL,w,h) {
winl = (screen.width - w) / 2;
wint = (screen.height - h) / 2;
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=1,scrollbars=1,location=0,status=1,menubar=0,resizable=1,width="+w+",height="+h+",top="+wint+",left="+winl+"');");}


function popUpfixed(URL,w,h) {
hh = (screen.height - 140);
if (hh >= h ) {hh = h};
winl = (screen.width - w) / 2;
wint = (screen.height - hh) / 10;
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,status=0,menubar=0,resizable=1,width="+w+",height="+hh+",top="+wint+",left="+winl+"');");}


function popUpfixednoscroll(URL,w,h) {
hh = (screen.height - 140);
if (hh >= h ) {hh = h};
winl = (screen.width - w) / 2;
wint = (screen.height - hh) / 10;
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,status=0,menubar=0,resizable=0,width="+w+",height="+hh+",top="+wint+",left="+winl+"');");}


function openNewWindow(url) {
hh = (screen.height - 200);
ww = (screen.width - 200);
wint = 20;
winl = 20;
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(url, '" + id + "','toolbar,scrollbars,location,status,menubar,resizable,width=" + ww + ",height=" + hh + ",top=" + wint + ",left=" + winl + "');");}


function PageWidth() {
pagewidth = 0;
if (self.innerWidth)
{
	pagewidth = self.innerWidth;
	return pagewidth;
}
else if (document.documentElement && document.documentElement.clientWidth)
{
	pagewidth = document.documentElement.clientWidth;
	return pagewidth;
}
else if (document.body)
{
	pagewidth = document.body.clientWidth;
	return pagewidth;
}
else return;}


function MaxTableWidth() {
width = PageWidth();
if (width >= 1024)
{
    tablewidth = '1000';
	return tablewidth;
}
else
{
    tablewidth = '95%';
	return tablewidth;
}}


function PageHeight() {
pageheight = 0;
if (self.innerHeight)
{
	pageheight = self.innerHeight;
	return pageheight;
}
else if (document.documentElement && document.documentElement.clientHeight)
{
	pageheight = document.documentElement.clientHeight;
	return pageheight;
}
else if (document.body)
{
	pageheight = document.body.clientHeight;
	return pageheight;
}
else return;}


function MaxTableHeight() {
height = PageHeight();
if (height >= 1024)
{
    tableheight = '1000';
	return tableheight;
}
else
{
    tableheight = (Math.round(((98 * height) / 100) - 54) + '');
	return tableheight;
}}


function MaxTableHeightDoubleMenu() {
height = PageHeight();
if (height >= 1024)
{
    tableheight = '1000';
	return tableheight;
}
else
{
    tableheight = (Math.round(((98 * height) / 100) - 78) + '');
	return tableheight;
}}


function DHTMLSound(surl) {
document.getElementById("soundspan").innerHTML="<embed src='"+surl+"' hidden=true autostart=true loop=false>";
}

