/*
* Countdown
*/
var CountdownJahr = 2012;
var CountdownMonat = 3;
var CountdownTag = 16;
var CountdownStunde = 18;
var CountdownMinute = 30;
var CountdownSekunde = 0;

var VeranstaltungZeit = new Date(CountdownJahr,CountdownMonat,CountdownTag+2,CountdownStunde,CountdownMinute,0);
var Inseln = new Array('Juist','Baltrum','Norderney','Borkum','Langeoog','Wangerooge','Spiekeroog');
var Jahr1 = 1996;
var jetzt = new Date();
var Zeit = jetzt.getTime();

var Jahr = jetzt.getFullYear()+2;

var Wiederholung = (Jahr-Jahr1)%7;
var iusInsel = "";

window.onload = function() 
{
	/*
    include('Javascript/prototype.js');
	include('Javascript/scriptaculous.js');
	include('Javascript/unittest.js');
    execute('drag();');
	*/
  getDocumentTitle();
}

function include(file) 
{
    var script = document.createElement('script');
    var type = document.createAttribute('type');
    type.nodeValue = 'text/javascript';
    script.setAttributeNode(type);
    var source = document.createAttribute('src');
    source.nodeValue = file;
    script.setAttributeNode(source);
    var head = document.getElementsByTagName('head')[0];
    head.appendChild(script);
}
function include_js(url)
{
  document.write(
                  unescape('%3Cscript%20type%3D%22text%2Fjavascript%22%20src%3D%22')+
                  url+
                  unescape('%22%3E%3C%2Fscript%3E')
                );
}

/* include_js('http://doktormolle.de/temp/269936.js'); */

function execute(code) 
{
    var i = 0;
    try {
        eval(code);
    } catch (e) {
        if (i < 20) {
            setTimeout('execute("' + code + '");', 1);
        }
        i++;
    }
}
function init() 
{
	createInsel();
	//iusInsel = "Spiekeroog";
	StatusCheck();
	Countdown();
	//window.onmousemove=mouse(event);
}
function createInsel() {
	for (x=0;x<Wiederholung;x++) 
	{
	 if(Zeit <= VeranstaltungZeit) {
		iusInsel = Inseln[x-1];
	 } else {
		iusInsel = Inseln[x];
   }
	}
}

function StatusCheck() 
{
    if(document.readyState != "complete") {
        window.setTimeout(StatusCheck, 100);
        return false;
    }
    window.setTimeout(Countdown, 100);
}

function Ausgabe() 
{
    alert("Hallo Welt!");
}
/* Gets the browser specific XmlHttpRequest Object */
function getXmlHttpRequestObject() 
{
	if (window.XMLHttpRequest) {
		return new XMLHttpRequest();
	} else if(window.ActiveXObject) {
		return new ActiveXObject("Microsoft.XMLHTTP");
	} else {
		alert("Ihr Browser ist veraltet!\nSie sollten Ihn auf eine neuere Version updaten.");
	}
}
function getNewHttpObject() { 
	var objType = false; 
	try {
		objType = new ActiveXObject('Msxml2.XMLHTTP');
	}
	 catch(e) {
	 	try {
		 	objType = new ActiveXObject('Microsoft.XMLHTTP'); 
		} 
		catch(e) {
			try {
				objType = new XMLHttpRequest();
			}
			catch(e) {
				alert("DE: Ihr Browser ist veraltet!\nSie sollten Ihn auf eine neuere Version aktualisieren.\nEN: Your Browser Sucks!\nIt's about time to upgrade don't you think?");
			}		 	 
		 }
	}
 return objType; 
}

/* Our XmlHttpRequest object to get the auto suggest */
var searchReq = getNewHttpObject();

/*
* Called from keyup on the search textbox.
* Starts the AJAX request.
*/
function searchSuggest() 
{
	if (searchReq.readyState == 4 || searchReq.readyState == 0) {
		var str = escape(document.getElementById('Vereinsname').value);
		searchReq.open("GET", 'searchSuggest.php?typ=Verein&search=' + str, true);
		searchReq.onreadystatechange = handleSearchSuggest; 
		searchReq.send(null);
	}		
}

/* Called when the AJAX response is returned. */
function handleSearchSuggest() 
{
	if (searchReq.readyState == 4) {
		var ss = document.getElementById('search_suggest');
		ss.innerHTML = '';
		var str = searchReq.responseText.split("\n");
		for(i=0; i < str.length - 1; i++) {
			/*
			* Build our element string.  This is cleaner using the DOM, but
			* IE doesn't support dynamically added attributes.
			*/
			var suggest = '<div onmouseover="javascript:suggestOver(this);" ';
			suggest += 'onmouseout="javascript:suggestOut(this);" ';
			suggest += 'onclick="javascript:setSearch(this.innerHTML);" ';
			suggest += 'class="suggest_link">' + str[i] + '</div>';
			ss.innerHTML += suggest;
		}
	}
}

/* Mouse over function */
function suggestOver(div_value) 
{
	div_value.className = 'suggest_link_over';
}

/* Mouse out function */
function suggestOut(div_value) 
{
	div_value.className = 'suggest_link';
}
/* Click function */
function setSearch(value) 
{
	var value = value.split("</span>");
	var id = value[0];
	var searchID = new RegExp("([0-9]{1,3})");
	id = searchID.exec(id);
	document.getElementById('Vereinsname').value = value[1];
	document.getElementById('vID').value = id[0];
	document.getElementById('search_suggest').innerHTML = '';
}
var objYpos = '';
var docTitle = '';
function searchAdress(obj, objValue) 
{
	objYpos = findPosY(obj);
	docTitle = getDocumentTitle();
	if (searchReq.readyState == 4 || searchReq.readyState == 0) {
		var str = escape(objValue);
		searchReq.open("GET", 'searchSuggest.php?typ=Mitglieder&search=' + str, true);
		searchReq.onreadystatechange = handleSearchAdress; 
		searchReq.send(null);
	}		
}
function getDocumentTitle() {
	var docTitle = document.title;
	docTitle = docTitle.split(":");
}
function handleSearchAdress() 
{
		var ss = document.getElementById('vcard');
		ss.innerHTML = '';
		var str = searchReq.responseText;
		ss.innerHTML = str;
		
		ss.style.top = objYpos;
		ss.style.visibility="visible";
}
var XMLHttpReq = null;
function getAdress() {
	XMLHttpReq = null;
	XMLHttpReq = getNewHttpObject();
	XMLHttpReq.open("GET", 'adress.grid.php', true);
	XMLHttpReq.onreadystatechange = handleGetAdress; 
	XMLHttpReq.send(null);
}
function handleGetAdress() 
{
	var li = document.getElementById('load_image');
	var ss = document.getElementById('adress_grid');
	ss.innerHTML = '';
	if (XMLHttpReq.readyState == 4) {
		if (XMLHttpReq.status == 200) {
			var str = XMLHttpReq.responseText;
			ss.innerHTML = str;
			li.style.display='none'
			ss.style.visibility="visible";
			execJS(ss);
		}
	}		
}
function execJS(node) {
 /* Element auf Javascript überprüfen, und falls nötig ausführen */
 var bSaf = (navigator.userAgent.indexOf('Safari') != -1);
 var bOpera = (navigator.userAgent.indexOf('Opera') != -1);
 var bMoz = (navigator.appName == 'Netscape');
 var st = node.getElementsByTagName('script'); var strExec;
   
 for(var i=0;i<st.length; i++) { if (bSaf) { strExec = st[i].innerHTML; } else if (bOpera) { strExec = st[i].text; }
   else if (bMoz) { strExec = st[i].textContent; } else { strExec = st[i].text; } try { eval(strExec); } catch(e) { alert(e);}}}

/**
* Price calculate function
*/
function FormatCurrency(anAmount) 
{
	if (anAmount.indexOf (".") == -1)
		anAmount = anAmount.concat(".00");
	else
		anAmount = anAmount.concat("0");

	anAmount = anAmount.substring(0, anAmount.indexOf (".") + 3);
	anAmount = anAmount.substring(0, anAmount.length - 3) + "," + anAmount.substring(anAmount.length - 2);
	return anAmount;
}

function BerechnePreise() 
{
	var frm = document.forms[0];
	var KatPreis = frm.Kategorie.options[frm.Kategorie.selectedIndex].value;
	var Personen = frm.Personen.value;
	var betrag = new String(Math.round((KatPreis * Personen) * 100) / 100);
	betrag = FormatCurrency(betrag);
	frm.Gesamtpreis.value = betrag;
}

/*
* Menue functionen
*/
function ShowMenue(subLevel) 
{
	var subLevel = document.getElementById('MenueMitglieder');
	subLevel.innerHTML = 'ndern<br/>Neues Mitglied<br/>';
}


function Countdown() 
{
    var Jetzt = new Date();
    var Countdown = new Date(CountdownJahr, CountdownMonat-1, CountdownTag, CountdownStunde, CountdownMinute, CountdownSekunde);
    var MillisekundenBisCountdown = Countdown.getTime()-Jetzt.getTime();
    var Rest = Math.floor(MillisekundenBisCountdown/1000);
    var CountdownText = "Noch ";

    if(Rest >= 31536000) {
        var Jahre = Math.floor(Rest/31536000);
        Rest = Rest-Jahre*31536000;

        if(Jahre > 1 || Jahre == 0) {
            CountdownText += Jahre + " Jahre ";
        } else if(Jahre == 1) {
            CountdownText += Jahre + " Jahr ";
        }
    }
    if(Rest >= 86400) {
        var Tage = Math.floor(Rest/86400);
        Rest = Rest-Tage*86400;

        if(Tage > 1 || Tage == 0) {
            CountdownText += Tage + " Tage ";
        } else if(Tage == 1) {
            CountdownText += Tage + " Tag ";
        }
    }
    if(Rest >= 3600) {
        var Stunden = Math.floor(Rest/3600);
        Rest = Rest-Stunden*3600;

        if(Stunden > 1 || Stunden == 0) {
            CountdownText += Stunden + " Stunden ";
        } else if(Stunden == 1) {
            CountdownText += Stunden + " Stunde ";
        }
    }
    if(Rest >= 60) {
        var Minuten = Math.floor(Rest/60);
        Rest = Rest-Minuten*60;

        if(Minuten > 1 || Minuten == 0) {
            CountdownText += Minuten + " Minuten ";
        } else if(Minuten == 1) {
            CountdownText += Minuten + " Minute ";
        }
    }

    if(Rest > 1 || Rest == 0) {
        CountdownText += Rest + " Sekunden ";
    } else if(Rest==1) {
        CountdownText += Rest + " Sekunde ";
    }

    document.getElementById('Countdown').innerHTML = CountdownText + "<br/>bis zum Inseltreffen auf " + iusInsel + "!";
    window.setTimeout("Countdown()", 1000);
}
/*
* Formular funktionen
*/
function ButtonAendern(Button, Text) 
{
    Button.value = Text;
    return true;
}

function clone_this_before(objButton,elmId) 
{
	if(objButton.parentNode)  {
		tmpNode = objButton.form.elements[0].parentNode.cloneNode(true);
		tmpCheckbox = document.getElementById(elmId);
		objButton.form.insertBefore(tmpNode,tmpCheckbox);
		var Knoten = document.form[0].getElementsByTagName("div")[0].firstChild;
		alert(Knoten);
		for(j=0;j<objButton.form.elements[0].parentNode.childNodes.length;++j) {
			if(objButton.form.elements[0].parentNode.childNodes[j].type=='text') {
				objButton.form.elements[0].parentNode.childNodes[j].value='';
				break;
            }
        }
		objButton.style.visibility='visible';
		objButton.value="löschen";
		objButton.onclick=new Function('f1','this.form.removeChild(this.parentNode)');
    }    
}

function clone_this(objButton) 
{
	if(objButton.parentNode) {
		objButton.previousSibling.firstChild.value='';	    
		tmpNode=objButton.parentNode.cloneNode(true);
	    objButton.form.appendChild(tmpNode);
	    for(j=0;j<objButton.form.lastChild.childNodes.length;++j) {
	        if(objButton.form.lastChild.childNodes[j].type=='text') {
	            objButton.form.lastChild.childNodes[j].value='';
	            break;
	        }
	    }
		
	    objButton.value="entfernen";
	    objButton.onclick=new Function('f1','this.form.removeChild(this.parentNode)');
    }
}

/*
* date select
*/
function TageBestimmen() 
{
    var Tag = document.getElementById("Tag").value;
    var Monat = document.getElementById("Monat").value;
    var Jahr = document.getElementById("Jahr").value;

    var TageImFebruar = 28;

    if((Jahr%4 == 0 && Jahr%100 !=0) || Jahr%400 == 0)
    {
        var TageImFebruar = 29;
    }

    var Tage = new Array(31, TageImFebruar, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31);

    document.getElementById("Tag").options.length = Tage[Monat-1];

    for(i = 0; i < Tage[Monat-1]; i++)
    {
        document.getElementById("Tag").options[i].text = i+1;
        document.getElementById("Tag").options[i].value = i+1;
    }
}

/**
* tooltip
*/
var Initialisierung = 0;
var Ex, Ey, TitelFarbe, TextFarbe, ContentInfo;

var TitelFarbe = "red";
var TextFarbe = "yellow";


function ToolTipBewegen(layerName, FromTop, FromLeft, e) 
{
    document.getElementById(layerName).style.top = FromTop;
    document.getElementById(layerName).style.left = FromLeft + 15;
}


function Aktivieren() 
{
    Initialisierung = 1;
}


function Deaktivieren() 
{
    Initialisierung = 0;
}


function Starten(e) 
{
    if(Initialisierung)
    {
        Ex = document.all ? window.event.x : e.pageX;
        Ey = document.all ? window.event.y : e.pageY;
        ToolTipBewegen("ToolTip", Ey, Ex, e);
        document.getElementById('ToolTip').style.visibility = "visible";
    }
    else
    {
        ToolTipBewegen("ToolTip", 0, 0);
        document.getElementById('ToolTip').style.visibility = "hidden";
    }
}

var XPosition = 10;
var YPosition = 20;
var MouseOverObjekt, objVcard;
var Anzeige = -1000;

function mouse(e) 
{
    x = document.all ? window.event.x : e.pageX;
    y = document.all ? window.event.y : e.pageY;

    objVcard.left = x+XPosition;
    objVcard.top = y+Anzeige;
}
function MouseOver(Grafik) 
{         
    Anzeige = YPosition;
    document.getElementById('vcard').innerHTML = Grafik;
    objVcard.visibility = "visible";
}


function ToolTip(layerName, TTitel, TInhalt) 
{
    ContentInfo = '<div class="ToolTipDiv">';
	ContentInfo += '<div class="ToolTipTitel"> '+TTitel+'</div>';
	ContentInfo += '<div class="ToolTipInhalt">'+TInhalt+'</div>';
	ContentInfo += '</div>';
    document.getElementById(layerName).innerHTML = ContentInfo;
}

function changeColor(objHover, backColor, fontColor) 
{
	if(!document.layers) {
		objHover.style.backgroundColor=backColor;
	} else {
		objHover.bgColor=backColor;
	}
	objHover.style.color = fontColor;
}
/** 
* Cookie Functions -- "Night of the Living Cookie" Version (25-Jul-96)
*
* Written by:  Bill Dortch, hIdaho Design <bdortch@hidaho.com>
* The following functions are released to the public domain.
* 
* Look at http://www.java2s.com/Code/JavaScript/Development/BillDortchsCookieFunctions.htm
* for more Information
*/
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 setCookie(name, value, expires, path, domain, secure) 
{
	document.cookie = name + "=" + escape(value) +
	((expires) ? "; expires=" + expires.toGMTString() : "") + 
	((path) ? "; path=" + path : "") +
	((domain) ? "; domain=" + domain : "") + 
	((secure) ? "; 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 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 deleteCookie (name,path,domain) 
{
  if (getCookie(name)) {
    document.cookie = name + "=" +
      ((path) ? "; path=" + path : "") +
      ((domain) ? "; domain="  + domain : "") +
      "; expires=Thu, 01-Jan-70 00:00:01 GMT";
  }
}
/**
* End of Cookie Functions
*/
var newurl

function CheckRequest(string) 
{
    if (confirm(string)) {
      return true
    } else {
      return false
    }
}

function findPosX(obj) 
{      
     var curleft = 0;
     if (obj.offsetParent)
     {
         while (obj.offsetParent)
         {
             curleft += obj.offsetLeft;
             obj = obj.offsetParent;
         }
     }
     return curleft;
}
  
function findPosY(obj) 
{
     var curtop = 0;
     if (obj.offsetParent)
     {
         while (obj.offsetParent)
         {
             curtop += obj.offsetTop;
             obj = obj.offsetParent;
         }
     }
     return curtop;
}


/* Tab Part */
function tabberObj(argsObj)
{var arg;this.div=null;this.classMain="tabber";this.classMainLive="tabberlive";this.classTab="tabbertab";this.classTabDefault="tabbertabdefault";this.classNav="tabbernav";this.classTabHide="tabbertabhide";this.classNavActive="tabberactive";this.titleElements=['h2','h3','h4','h5','h6'];this.titleElementsStripHTML=true;this.removeTitle=true;this.addLinkId=false;this.linkIdFormat='<tabberid>nav<tabnumberone>';for(arg in argsObj){this[arg]=argsObj[arg];}
this.REclassMain=new RegExp('\\b'+this.classMain+'\\b','gi');this.REclassMainLive=new RegExp('\\b'+this.classMainLive+'\\b','gi');this.REclassTab=new RegExp('\\b'+this.classTab+'\\b','gi');this.REclassTabDefault=new RegExp('\\b'+this.classTabDefault+'\\b','gi');this.REclassTabHide=new RegExp('\\b'+this.classTabHide+'\\b','gi');this.tabs=new Array();if(this.div){this.init(this.div);this.div=null;}}
tabberObj.prototype.init=function(e)
{var
childNodes,i,i2,t,defaultTab=0,DOM_ul,DOM_li,DOM_a,aId,headingElement;if(!document.getElementsByTagName){return false;}
if(e.id){this.id=e.id;}
this.tabs.length=0;childNodes=e.childNodes;for(i=0;i<childNodes.length;i++){if(childNodes[i].className&&childNodes[i].className.match(this.REclassTab)){t=new Object();t.div=childNodes[i];this.tabs[this.tabs.length]=t;if(childNodes[i].className.match(this.REclassTabDefault)){defaultTab=this.tabs.length-1;}}}
DOM_ul=document.createElement("ul");DOM_ul.className=this.classNav;for(i=0;i<this.tabs.length;i++){t=this.tabs[i];t.headingText=t.div.title;if(this.removeTitle){t.div.title='';}
if(!t.headingText){for(i2=0;i2<this.titleElements.length;i2++){headingElement=t.div.getElementsByTagName(this.titleElements[i2])[0];if(headingElement){t.headingText=headingElement.innerHTML;if(this.titleElementsStripHTML){t.headingText.replace(/<br>/gi," ");t.headingText=t.headingText.replace(/<[^>]+>/g,"");}
break;}}}
if(!t.headingText){t.headingText=i+1;}
DOM_li=document.createElement("li");t.li=DOM_li;DOM_a=document.createElement("a");DOM_a.appendChild(document.createTextNode(t.headingText));DOM_a.href="javascript:void(null);";DOM_a.title=t.headingText;DOM_a.onclick=this.navClick;DOM_a.tabber=this;DOM_a.tabberIndex=i;if(this.addLinkId&&this.linkIdFormat){aId=this.linkIdFormat;aId=aId.replace(/<tabberid>/gi,this.id);aId=aId.replace(/<tabnumberzero>/gi,i);aId=aId.replace(/<tabnumberone>/gi,i+1);aId=aId.replace(/<tabtitle>/gi,t.headingText.replace(/[^a-zA-Z0-9\-]/gi,''));DOM_a.id=aId;}
DOM_li.appendChild(DOM_a);DOM_ul.appendChild(DOM_li);}
e.insertBefore(DOM_ul,e.firstChild);e.className=e.className.replace(this.REclassMain,this.classMainLive);this.tabShow(defaultTab);if(typeof this.onLoad=='function'){this.onLoad({tabber:this});}
return this;};tabberObj.prototype.navClick=function(event)
{var
rVal,a,self,tabberIndex,onClickArgs;a=this;if(!a.tabber){return false;}
self=a.tabber;tabberIndex=a.tabberIndex;a.blur();if(typeof self.onClick=='function'){onClickArgs={'tabber':self,'index':tabberIndex,'event':event};if(!event){onClickArgs.event=window.event;}
rVal=self.onClick(onClickArgs);if(rVal===false){return false;}}
self.tabShow(tabberIndex);return false;};tabberObj.prototype.tabHideAll=function()
{var i;for(i=0;i<this.tabs.length;i++){this.tabHide(i);}};tabberObj.prototype.tabHide=function(tabberIndex)
{var div;if(!this.tabs[tabberIndex]){return false;}
div=this.tabs[tabberIndex].div;if(!div.className.match(this.REclassTabHide)){div.className+=' '+this.classTabHide;}
this.navClearActive(tabberIndex);return this;};tabberObj.prototype.tabShow=function(tabberIndex)
{var div;if(!this.tabs[tabberIndex]){return false;}
this.tabHideAll();div=this.tabs[tabberIndex].div;div.className=div.className.replace(this.REclassTabHide,'');this.navSetActive(tabberIndex);if(typeof this.onTabDisplay=='function'){this.onTabDisplay({'tabber':this,'index':tabberIndex});}
return this;};tabberObj.prototype.navSetActive=function(tabberIndex)
{this.tabs[tabberIndex].li.className=this.classNavActive;return this;};tabberObj.prototype.navClearActive=function(tabberIndex)
{this.tabs[tabberIndex].li.className='';return this;};function tabberAutomatic(tabberArgs)
{var
tempObj,divs,i;if(!tabberArgs){tabberArgs={};}
tempObj=new tabberObj(tabberArgs);divs=document.getElementsByTagName("div");for(i=0;i<divs.length;i++){if(divs[i].className&&divs[i].className.match(tempObj.REclassMain)){tabberArgs.div=divs[i];divs[i].tabber=new tabberObj(tabberArgs);}}
return this;}
function tabberAutomaticOnLoad(tabberArgs)
{var oldOnLoad;if(!tabberArgs){tabberArgs={};}
oldOnLoad=window.onload;if(typeof window.onload!='function'){window.onload=function(){tabberAutomatic(tabberArgs);};}else{window.onload=function(){oldOnLoad();tabberAutomatic(tabberArgs);};}}
if(typeof tabberOptions=='undefined'){tabberAutomaticOnLoad();}else{if(!tabberOptions['manualStartup']){tabberAutomaticOnLoad(tabberOptions);}}
/* Password indicator*/
var nCrackrate = 1000; 
var nTreshholddays = 365 * 10; 
var nSteps = 10;
function contains(strText, strPattern){
	for (i = 0; i < strText.length; i++){
		if (strPattern.indexOf(strText.charAt(i)) > -1) return true;
	}
	return false;
}
function checkPass(strPass, strId, strClassname, strTextId, aTexts){
	nCombinationCount = 0;
	strToCheck = "0123456789";
	if (contains(strPass, strToCheck)) {
		nCombinationCount += strToCheck.length;
	}
	strToCheck = "abcdefghijklmnopqrstuvwxyz";
	if (contains(strPass, strToCheck)) {
		nCombinationCount += strToCheck.length;
	}
	strToCheck = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
	if (contains(strPass, strToCheck)) {
		CombinationCount += strToCheck.length;
	}
	strToCheck = ",;:-_=+|//?^&!.@$#*()%~<>{}[]";
	if (contains(strPass, strToCheck)) {
		nCombinationCount += strToCheck.length;
	}
	var nDays = ((Math.pow(nCombinationCount, strPass.length) / nCrackrate) / 2) / 86400;
	var nStrongness = Math.round(nDays / nTreshholddays * 100);
	if (nStrongness < (strPass.length * 5)) {
		nStrongness += strPass.length * 5;
	}
	if (nStrongness > 100) {
		nStrongness = 100;
	}
	nStrongness = Math.round(nStrongness / (100 / nSteps));
	oId = document.getElementById(strId);
	oId.className = strClassname + - + nStrongness;otId = document.getElementById(strTextId);
	if (aTexts){
		nKey = Math.round((aTexts.length - 1) / nSteps * nStrongness);
		otId.innerHTML = aTexts[nKey];
	}
}
function verifynotify(field1, field2, result_id, match_html, nomatch_html) {this.field1 = field1;this.field2 = field2;this.result_id = result_id;this.match_html = match_html;this.nomatch_html = nomatch_html;this.check = function() {if (!this.result_id) { return false; }if (!document.getElementById){ return false; }r = document.getElementById(this.result_id);if (!r){ return false; }if (this.field1.value != "" && this.field1.value == this.field2.value) {r.innerHTML = this.match_html;} else {r.innerHTML = this.nomatch_html;}}}


