//
//inhibit right mouse for IE and Netscape
//
{
var message="We are sorry but you do not have permission to do that";
function click(e) {
if (document.all) {
if (navigator.appName == 'Netscape' && e.which == 3) {
alert(message);
return false;
}
else if (navigator.appName == 'Microsoft Internet Explorer' && event.button==2) {
alert(message);
return false;
}
else if (navigator.appName == 'Opera' && e.button != 1) {
alert(message);
return false;
}
}
else if (document.layers||document.getElementById) {
if (navigator.appName == 'Netscape' && e.which == 3) {
alert(message);
return false;
}
else if (navigator.appName == 'Microsoft Internet Explorer' && e.which == 2) {
alert(message);
return false;
}
else if (navigator.appName == 'Opera' && e.button != 1) {
alert(message);
return false;
}
}
}
document.onmousedown=click;
document.onmouseup=click;
if (document.layers) window.captureEvents(Event.MOUSEDOWN);
if (document.layers) window.captureEvents(Event.MOUSEUP);
window.onmousedown=click;
window.onmouseup=click;
}
function cache_image(image_url)
{temp_image= new Image();
temp_image.src = image_url;
}
//
// Error Supression
//
function blockError(){return true;}
//
// It detects which browser is being used.
//
function WhichBrowser() {
var agent = navigator.userAgent;
var browserName = navigator.appName;
var version = parseInt(navigator.appVersion);
if (browserName == "Microsoft Internet Explorer") this.brows = "IE";
else if (browserName == "Netscape") this.brows = "NN";
else this.brows = browserName;
if (agent.indexOf('MSIE 5') != -1) this.ver = 5;
else this.ver = version;
this.IE5 = (agent.indexOf('MSIE 5') != -1);
this.IE6 = (agent.indexOf('MSIE 6') != -1)||(agent.indexOf('MSIE 7') != -1)||(agent.indexOf('MSIE 8') != -1);
this.FX = (agent.indexOf('Firefox/1') != -1)||(agent.indexOf('Firefox/2') != -1);
this.OPERA = (agent.indexOf('Opera') != -1);
this.O7 = (agent.indexOf('Opera 7') != -1)||(agent.indexOf('Opera 8') != -1);
this.NN4 = (this.brows == "NN" && this.ver == 4);
this.NN5 = (this.brows == "NN" && this.ver == 5);
this.NN6 = (agent.indexOf('Netscape/6') != -1);
this.NN7 = (agent.indexOf('Netscape/7') != -1)||(agent.indexOf('Netscape/8') != -1);;
this.CSS = (this.IE5||this.IE6||this.NN6||this.NN7||this.FX);
this.IE5PLUS = (this.IE5||this.IE6);
this.XMLOK = (this.IE5||this.IE6||this.NN7||this.FX);
}
//
// Gets and outputs the date and time
//
function CurrentDateTime() {
mydate = new Date();
myday = mydate.getDay();
mymonth = mydate.getMonth();
myweekday= mydate.getDate();
myyear= mydate.getYear();
year = myyear;
if (year < 2000)    // Y2K Fix, Isaac Powell
year = year + 1900; // http://onyx.idbsu.edu/~ipowell
myhours = mydate.getHours();
if (myhours >= 12) {
myhours = (myhours == 12) ? 12 : myhours - 12; mm = " pm";
}
else {
myhours = (myhours == 0) ? 12 : myhours; mm = " am";
}
myminutes = mydate.getMinutes();
if (myminutes < 10){
mytime = ":0" + myminutes;
}
else {
mytime = ":" + myminutes;
};
arday = new Array("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday")
armonth = new Array("January ","February ","March ","April ","May ","June ","July ","August ","September ", "October ","November ","December ")
ardate = new Array("0th","1st","2nd","3rd","4th","5th","6th","7th","8th","9th","10th","11th","12th","13th","14th","15th","16th","17th","18th","19th","20th","21st","22nd","23rd","24th","25th","26th","27th","28th","29th","30th","31st");
// rename locale as needed.
this.datetime = (arday[myday] +", " + armonth[mymonth] +" "+ardate[myweekday] + " " + year+ " @ " + myhours + mytime+ mm );
this.day = arday[myday]
this.time = myhours + mytime+ mm
this.date = arday[myday] +", " + armonth[mymonth] +" "+ardate[myweekday] + ", " + year
this.year =  year
}
//
//
//
function FixCookieDate (date) {
var base = new Date(0);
var skew = base.getTime(); // dawn of (Unix) time - should be 0
if (skew > 0)  // Except on the Mac - ahead of its time
date.setTime (date.getTime() - skew);
}
//
//
//
function SetCookie (name,value,expires,path,domain,secure) {
document.cookie = name + "=" + escape (value) +
((expires) ? "; expires=" + expires.toGMTString() : "") +
((path) ? "; path=" + path : "") +
((domain) ? "; domain=" + domain : "") +
((secure) ? "; secure" : "");
}
//
//
//
function getCookieVal (offset) {
var endstr = document.cookie.indexOf (";", offset);
if (endstr == -1)
endstr = document.cookie.length;
return unescape(document.cookie.substring(offset, endstr));
}
//
//
//
function GetCookie (name) {
var arg = name + "=";
var alen = arg.length;
var clen = document.cookie.length;
var i = 0;
while (i < clen) {
var j = i + alen;
if (document.cookie.substring(i, j) == arg)
return getCookieVal (j);
i = document.cookie.indexOf(" ", i) + 1;
if (i == 0) break;
}
return null;
}
//
//
//
function smutEngine(field) {
    smut="#@&*%!#@&*%!#@&*%!";
    cmp="sex babes shit fuck damn porno cum cunt prick pecker ass "
            +"asshole pedophile man-boy man/boy dong twat "
       +"SEX BABES SHIT FUCK DAMN PORNO CUM CUNT PRICK PECKER ASS "
            +"ASSHOLE PEDOPHILE MAN-BOY MAN/BOY DONG TWAT "
    txt=field.value;
    tstx="";
    for (var i=0;i<34;i++){
    pos=cmp.indexOf(" ");
    wrd=cmp.substring(0,pos);
    wrdl=wrd.length
    cmp=cmp.substring(pos+1,cmp.length);
    while (txt.indexOf(wrd)>-1){
    pos=txt.indexOf(wrd);
    txt=txt.substring(0,pos)+smut.substring(0,wrdl)
    +txt.substring((pos+wrdl),txt.length);
       }
    }
    field.value=txt;
}
//
// creating instance of the whicbrowser/Today objects
//
var is = new WhichBrowser();
var today = new CurrentDateTime();
var gmt = " BST";
window.onerror = blockError;

