<!--

var overImg = null;
var normImg = null;

var loadDone = false;


////////////////////////////////////////////////////////////////////////
/* bookmark function for numeruos browsers  */

function bookmarkinit() {
var IE = navigator.appName.match(/(Microsoft Internet Explorer)/gi), 
    NS = navigator.appName.match(/(Netscape)/gi), 
    OP = navigator.appName.match(/(Opera)/gi), 
    BK = document.getElementById("bookmark");



    BK.onmouseout = function(){ 
       window.status = ''; 
       return true; 
    } 

    if(IE && document.uniqueID){ 
       BK.onclick = function(){ 
          window.external.AddFavorite(location.href,document.title); 
       } 
       BK.onmouseover = function(){ 
          window.status='Click to add this page to your '+RegExp.$1+' favorites'; 
          return true; 
       } 
    } 

    else if(OP || IE && !document.uniqueID){ 
       BK.onclick = function(){ 
          alert('Your '+RegExp.$1+' browser requires that you\nPress Ctrl & T to Bookmark this page.'); 
       } 
       BK.onmouseover = function(){ 
          window.status='Your '+RegExp.$1+' browser requires that you Press Ctrl & T to Bookmark this page.'; 
          return true; 
       } 
    } 

    else if(NS){ 
       BK.onclick = function(){ 
          alert('Your '+RegExp.$1+' browser requires that you\nPress Ctrl & D to Bookmark this page.'); 
       } 
       BK.onmouseover = function(){ 
          window.status='Your '+RegExp.$1+' browser requires that you press Ctrl & D to Bookmark this page.'; 
          return true; 
       } 
    } 

    else{ BK.innerHTML = '' }

}

///////////////////////////////////////////////////////////////////////////////////////////////


////////////////////////////////////////////////////////////////////////

/* function for body.onLoad */

function initPage() {
	preloadMenu(8);
	loadDone = true;
}

////////////////////////////////////////////////////////////////////////

/* functions for menu and other images */
function preloadMenu(count) {
	overImg = new preloadImages(count, "/data/images/design/menu/menu-", "-on.gif");
	normImg = new preloadImages(count, "/data/images/design/menu/menu-", "-off.gif");
}

function preloadImages(length, path, type) {
    for(var i = 2; i <= length; i++) {
	this[i]= new Image();
	this[i].src= path + i + type;
    }
    return this;
}

function rollOn(num) {
    if(loadDone && document.images) { 
	document.images["m-" + num].src = overImg[num].src;
    }
}

function rollOff(num) {
    if(loadDone && document.images){
	document.images["m-" + num].src = normImg[num].src;
    }
}

function sizeImg(obj, _width) {
    var tmpImg = new Image();
    tmpImg.src = obj.src;
    if (tmpImg.width > _width) { obj.width = _width; }
}

////////////////////////////////////////////////////////////////////////

/* function to open print\email window */

function PrinterFriendly(url) {
    var width = 700,
        height = 550;

    remote = window.open("http://" + getDomainName() + url, "opener", "scrollbars=1,resizable=1,toolbar=1,left=" + ((screen.availWidth  - width) / 2) + ",top=" + ((screen.availHeight  - height) / 2) + ",width=" + width + ",height=" + height);

    if (remote.opener == null) remote.opener = window;
}
function PrinterFriendlyNoPopup(url) {
    var width = 700;
        height = 550;

    remote = window.open("http://" + getDomainName() + url, "_self");

    if (remote.opener == null) remote.opener = window;
}

function PrinterFriendly760(url) {
    var width = 760,
        height = 560;
    remote = window.open("http://" + getDomainName() + url, "opener", "menubar=0,scrollbars=0,resizable=0,toolbar=0,left=" + ((screen.availWidth  - width) / 2) + ",top=" + ((screen.availHeight  - height) / 2) + ",Width=" + width + ",height=" + height);
    if (remote.opener == null) remote.opener = window;
}

function getDomainName() {
	var url = window.location.href;
	var end = url.indexOf("/", 7);
	if (end == -1) { end = url.length; }
	return url.substring(7, end);
}

/* function that show tip on your status bar when you take mouse over print\email link */

function showText(obj) {
    obj.onmouseout = function() { window.status = ""; }
    window.status = obj.innerText;
}

function sizeImgWH(obj, _width, _height) {
    var tmpImg = new Image();
    tmpImg.src = obj.src;
    if (tmpImg.width > _width) { obj.width = _width; }
    if (tmpImg.height > _height) { obj.height = _height; }
}

////////////////////////////////////////////////////////////////////////

/* functions that check different forms for correct information */



//-->

