var ver;
var imgloc = '/img/default/menu_';
window.onerror = null;
browser_name = navigator.appName;
browser_version = parseInt(navigator.appVersion); 
if (browser_name == "Netscape" && browser_version >= 3) {ver = 1;}
else if (browser_name == "Microsoft Internet Explorer" && browser_version >= 4) {ver = 1;}
else {ver = 0;}
if (ver == 1) 
{
a = new Image(); a.src= imgloc + 'start_over.gif';  
b = new Image(); b.src= imgloc + 'share_over.gif';      
c = new Image(); c.src= imgloc + 'link_over.gif'; 
d = new Image(); d.src= imgloc + 'add_over.gif'; 
e = new Image(); e.src= imgloc + 'comment_over.gif'; 

}
function roll(imagename,changeimageto)
{
    if (ver == 1) 
    {
    document.images[imagename].src = imgloc + changeimageto;
    }
}

function openWindow(url,width,height,status)
{
	width -= 12;
	height -= 31;
    PopURL=url;
    if(!PopWin || PopWin.closed){
        PopWin=PopWinOpen(width,height,status);
    }
    else {
        PopWin.close();
        PopWin=null;
        PopWin=PopWinOpen(width,height,status);
    }
}
var PopURL="";
var PopWin=null;
var openpopwin=null;
var calendar_span;
function PopWinOpen(width,height,status){
    var x =(screen.availWidth-width)/2;
    var y =(screen.availHeight-height)/2;
	var status_st = '';
	if(status)
	{
		status_st = ',status';
	}

	var date_obj = new Date();
	var date_st = '' + date_obj.getTime();

  var winfeatures="width="+width+",height="+height+",top="+y+",left="+x+",resizable=yes,scrollbars=1" + status_st;
	openpopwin=null;
	openpopwin=window.open(PopURL,"wkapp" + date_st,winfeatures);
	return openpopwin;
}
