//Browser Sniffer

window.name = "_thewindow";

browser = navigator.appName;

os = navigator.platform;

version = navigator.appVersion;

ie = "Microsoft Internet Explorer";

netscape = "Netscape";

mac = "MacPPC";



if(browser == netscape && os != mac) {

   document.write('<link rel=stylesheet type="text/css" href="/entertainment/css/index_n.css">');

} else if(os == mac && version.indexOf("5.") >= 0) {

   document.write('<link rel=stylesheet type="text/css" href="/entertainment/css/index_ie.css">');

} else if(browser == netscape && os == mac) {

   document.write('<link rel=stylesheet type="text/css" href="/entertainment/css/index_macn.css">');

} else if(browser == ie && os == mac) {

   document.write('<link rel=stylesheet type="text/css" href="/entertainment/css/index_macie.css">');

} else {

   document.write('<link rel=stylesheet type="text/css" href="/entertainment/css/index_ie.css">');

}



//Child Window

function pWindow(pPage) {

childWindow = window.open(pPage,'childWindow','status=yes,toolbar=yes,location=no,menu=yes,resizable=yes,scrollbars=yes,width=616,height=350');

childWindow.focus();

}

function formHandler(form)

{

var URL = document.form.site.options[document.form.site.selectedIndex].value;

window.location.href = URL;

}



//Date

d = new Array(

"Sunday",

"Monday",

"Tuesday",

"Wednesday",

"Thursday",

"Friday",

"Saturday"

);

m = new Array(

"January",

"February",

"March",

"April",

"May",

"June",

"July",

"August",

"September",

"October",

"November",

"December"

);

mm = new Array(

"01",

"02",

"03",

"04",

"05",

"06",

"07",

"08",

"09",

"10",

"11",

"12"

);


today = new Date();

day = today.getDate();

year = today.getYear();



if (year < 2000) 

year = year + 1900;



end = "th";

if (day==1 || day==21 || day==31) end="st";

if (day==2 || day==22) end="nd";

if (day==3 || day==23) end="rd";

day+=end;



function writeDate() {

document.write('<b>');

document.write(d[today.getDay()]+", "+m[today.getMonth()]+" ");

document.write(day+", " + year);

document.write('</b>&nbsp;');

}

function writeDateLink() {

document.write(year+mm+day);

}

// Frame-buster

if (window != top) top.location.href = location.href;



//popWinC

function popWinC()

{

}


//Popup Ad
/*
function setCookie(name, value, expires) {
    document.cookie = escape(name) + "=" + escape(value) + "; path=/" + 
        ((expires == null) ? "" : "; expires=" + expires.toGMTString(  ));
}

// Function to retrieve a cookie's value
function getCookie(name) {
    var cookiename = name + "=";
    var dc = document.cookie;
    var begin, end;

    if (dc.length > 0) {
        begin = dc.indexOf(cookiename);
        if (begin != -1) {
            begin += cookiename.length;
            end = dc.indexOf(";", begin);
            if (end == -1) {
                end = dc.length;
            }
            return unescape(dc.substring(begin, end));
        } 
    }
    return null;
}

if (getCookie('popup') == null){ 
var exp = new Date();               
exp.setTime(exp.getTime() + (1000 * 60 * 60 * 12));  
setCookie("popup", 1, exp);
var windowprops = "width=400,height=240,location=no,toolbar=no,menubar=no,scrollbars=no,resizable=no";
window.open("/Phorm/popup.html", "", windowprops); 
} 
*/