/*==========================================================================*\ || ######################################################################## || || # ILance 3.0.0 Release Candidate 1 - Enterprise Edition # || || # -------------------------------------------------------------------- # || || # Copyright ©2000–2004 EBusiness Conxions Inc. All Rights Reserved. # || || # This file may not be redistributed in whole or significant part. # || || # ----------------- ILANCE IS NOT FREE SOFTWARE ---------------------- # || || # http://www.ilance.ca | http://www.ilance.ca/license.html # || || # -------------------------------------------------------------------- # || || # Title........: Core JavaScript Functions || # -------------------------------------------------------------------- # || || ######################################################################## || || # CVS History and Technical Application Information || # -------------------------------------------------------------------- # || || # CVS: $RCSfile: clientscript.js,v $ || # CVS: $Version: 3.0.0 $ || # CVS: $Revision: 1.10 $ || # CVS: $Date: 2005/12/17 19:35:17 $ || # CVS: $Author: Peter Salzmann $ || # -------------------------------------------------------------------- # || || ######################################################################## || \*==========================================================================*/ if (typeof ILSESSION == 'undefined') { ILSESSION = ''; } var userAgent = navigator.userAgent.toLowerCase(); var checkopera = (userAgent.indexOf('opera') != -1); var checksaf = ((userAgent.indexOf('safari') != -1) || (navigator.vendor == "Apple Computer, Inc.")); var checkwebtv = (userAgent.indexOf('webtv') != -1); var checkie = ((userAgent.indexOf('msie') != -1) && (!checkopera) && (!checksaf) && (!checkwebtv)); var checkie4 = ((checkie) && (userAgent.indexOf("msie 4.") != -1)); var checkmoz = ((navigator.product == 'Gecko') && (!checksaf)); var checkns = ((userAgent.indexOf('compatible') == -1) && (userAgent.indexOf('mozilla') != -1) && (!checkopera) && (!checkwebtv) && (!checksaf)); var checkns4 = ((checkns) && (parseInt(navigator.appVersion) == 4)); var checkregexp = (window.RegExp) ? true : false; var DOMTYPE = ''; var AJAX_compatible = false; if (document.getElementById) { DOMTYPE = "std"; } else if (document.layers) { DOMTYPE = "ns4"; } else if (document.all) { DOMTYPE = "ie4"; } var v3objects = new Array(); function fetch_session_hash() { return (ILSESSION == '' ? '' : ILSESSION.substr(2, 32)); } function getv3obj(idobjname, obtainobj) { if (obtainobj || typeof(v3objects[idobjname]) == "undefined") { switch (DOMTYPE) { case "std": { v3objects[idobjname] = document.getElementById(idobjname); } break; case "ns4": { v3objects[idobjname] = document.layers[idobjname]; } break; case "ie4": { v3objects[idobjname] = document.all[idobjname]; } break; } } return v3objects[idobjname]; } function obtainv3cookie(name) { v3cookiename = name + "="; v3cookiesize = document.cookie.length; v3cookiestart = 0; while (v3cookiestart < v3cookiesize) { v3cookievalue = v3cookiestart + v3cookiename.length; if (document.cookie.substring(v3cookiestart, v3cookievalue) == v3cookiename) { var v3cookievalue2 = document.cookie.indexOf (";", v3cookievalue); if (v3cookievalue2 == -1) { v3cookievalue2 = v3cookiesize; } return unescape(document.cookie.substring(v3cookievalue, v3cookievalue2)); } v3cookiestart = document.cookie.indexOf(" ", v3cookiestart) + 1; if (v3cookiestart == 0) { break; } } return null; } function updatev3cookie(name, value, expires) { if (!expires) { expires = new Date(); } document.cookie = name + "=" + escape(value) + "; expires=" + expires.toGMTString() + "; path=/"; } function updatev3collapsablecookie(objid, setcookiedata) { var cookiedata = obtainv3cookie("ilance_collapse"); var cookietemp = new Array(); if (cookiedata != null) { cookiedata = cookiedata.split("\n"); for (i in cookiedata) { if (cookiedata[i] != objid && cookiedata[i] != "") { cookietemp[cookietemp.length] = cookiedata[i]; } } } if (setcookiedata) { cookietemp[cookietemp.length] = objid; } cookieexpire = new Date(); cookieexpire.setTime(cookieexpire.getTime()+(500*86400*365)); updatev3cookie("ilance_collapse", cookietemp.join("\n"), cookieexpire); } function toggle(objid) { if (!checkregexp) { return false; } obj = getv3obj("collapseobj_" + objid); img = getv3obj("collapseimg_" + objid); if (obj.style.display == "none") { obj.style.display = ""; updatev3collapsablecookie(objid, false); if (img) { img_re = new RegExp("_collapsed\\.gif$"); img.src = img.src.replace(img_re, '.gif'); } } else { obj.style.display = "none"; updatev3collapsablecookie(objid, true); if (img) { img_re = new RegExp("\\.gif$"); img.src = img.src.replace(img_re, '_collapsed.gif'); } } return false; } function toggleclosefilter(target) { obj=(document.all) ? document.all[target] : document.getElementById(target); obj.style.display=(obj.style.display=='none') ? 'none' : 'none'; } function toggleclosestartdate(target) { obj=(document.all) ? document.all[target] : document.getElementById(target); obj.style.display=(obj.style.display=='none') ? 'none' : 'none'; } function togglepulldown(id,text) { d=document.getElementById(id); d.innerHTML=text; } var checkobj function agreesubmit(el) { checkobj=el if (document.all||document.getElementById) { for (i=0;i0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);} if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i