// JavaScript Document
function changeClass(id, class_name) {
	id.className = class_name;
}
function openHelpBox() {
	document.getElementById('help').style.visibility = 'visible';
}
function getInternetExplorerVersion()
// Returns the version of Internet Explorer or a -1
// (indicating the use of another browser).
{
	var rv = -1; // Return value assumes failure.
	if (navigator.appName == 'Microsoft Internet Explorer') {
		var ua = navigator.userAgent;
		var re = new RegExp("MSIE ([0-9]{1,}[\.0-9]{0,})");
		if (re.exec(ua) != null)
			rv = parseFloat(RegExp.$1);
	}
	return rv;
}
/**
 * get the version of ie
 */
function ieVersion() {
	var msg = "You're not using Internet Explorer.";
	var ver = getInternetExplorerVersion();
	return ver;
}
/**
 * javascript get the page name
 * @return
 */
function pageName() {
	var sPath = window.location.pathname;
	var sPage = sPath.substring(sPath.lastIndexOf('/') + 1);
	return sPage;
}
function deleteGroup(id)
{
	var msg = confirm('this group will be deleted \n all photos on group will be deleted \n all comments on this group will be deleted \n are you sure you want to delete this group ?');
	if(msg)
		ajaxPageNoOutput('ajax/page_no_output.php','group_id='+id+'&page=delete_group');
}
function popUp(URL,width,height) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width="+width+",height="+height+",left = 433,top = 134');");
}
