// JavaScript Document/************************************************ Show Hint script- © Dynamic Drive (www.dynamicdrive.com)* This notice MUST stay intact for legal use* Visit http://www.dynamicdrive.com/ for this script and 100s more.***********************************************/		var horizontal_offset="9px" //horizontal offset of hint box from anchor link/////No further editting neededvar vertical_offset="0" //horizontal offset of hint box from anchor link. No need to change.var ie=document.allvar ns6=document.getElementById&&!document.allfunction getposOffset(what, offsettype){var totaloffset=(offsettype=="left")? what.offsetLeft : what.offsetTop;var parentEl=what.offsetParent;while (parentEl!=null){totaloffset=(offsettype=="left")? totaloffset+parentEl.offsetLeft : totaloffset+parentEl.offsetTop;parentEl=parentEl.offsetParent;}return totaloffset;}function iecompattest(){return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body}function clearbrowseredge(obj, whichedge){var edgeoffset=(whichedge=="rightedge")? parseInt(horizontal_offset)*-1 : parseInt(vertical_offset)*-1if (whichedge=="rightedge"){var windowedge=ie && !window.opera? iecompattest().scrollLeft+iecompattest().clientWidth-30 : window.pageXOffset+window.innerWidth-40dropmenuobj.contentmeasure=dropmenuobj.offsetWidthif (windowedge-dropmenuobj.x < dropmenuobj.contentmeasure)edgeoffset=dropmenuobj.contentmeasure+obj.offsetWidth+parseInt(horizontal_offset)}else{var windowedge=ie && !window.opera? iecompattest().scrollTop+iecompattest().clientHeight-15 : window.pageYOffset+window.innerHeight-18dropmenuobj.contentmeasure=dropmenuobj.offsetHeightif (windowedge-dropmenuobj.y < dropmenuobj.contentmeasure)edgeoffset=dropmenuobj.contentmeasure-obj.offsetHeight}return edgeoffset}function showhint(menucontents, obj, e, tipwidth){if ((ie||ns6) && document.getElementById("hintbox")){dropmenuobj=document.getElementById("hintbox")dropmenuobj.innerHTML=menucontentsdropmenuobj.style.left=dropmenuobj.style.top=-500if (tipwidth!=""){dropmenuobj.widthobj=dropmenuobj.styledropmenuobj.widthobj.width=tipwidth}dropmenuobj.x=getposOffset(obj, "left")dropmenuobj.y=getposOffset(obj, "top")dropmenuobj.style.left=dropmenuobj.x-clearbrowseredge(obj, "rightedge")+obj.offsetWidth+"px"dropmenuobj.style.top=dropmenuobj.y-clearbrowseredge(obj, "bottomedge")+"px"dropmenuobj.style.visibility="visible"obj.onmouseout=hidetip}}function hidetip(e){dropmenuobj.style.visibility="hidden"dropmenuobj.style.left="-500px"}function createhintbox(){var divblock=document.createElement("div")divblock.setAttribute("id", "hintbox")document.body.appendChild(divblock)}if (window.addEventListener)window.addEventListener("load", createhintbox, false)else if (window.attachEvent)window.attachEvent("onload", createhintbox)else if (document.getElementById)window.onload=createhintboxfunction MM_preloadImages() { //v3.0  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}}function MM_swapImgRestore() { //v3.0  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;}function MM_findObj(n, d) { //v4.01  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&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<d.forms.length;i++) x=d.forms[i][n];  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);  if(!x && d.getElementById) x=d.getElementById(n); return x;}function MM_swapImage() { //v3.0  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}}<!-- Original:  Ronnie T. Moore --><!-- Web Site:  The JavaScript Source --><!-- Dynamic 'fix' by: Nannette Thacker --><!-- Web Site: http://www.shiningstar.net --><!-- This script and many more are available free online at --><!-- The JavaScript Source!! http://javascript.internet.com --><!-- Beginfunction textCounter(field, countfield, maxlimit) {if (field.value.length > maxlimit) // if too long...trim it!field.value = field.value.substring(0, maxlimit);// otherwise, update 'characters left' counterelse countfield.value = maxlimit - field.value.length;}// End -->function MM_goToURL() { //v3.0  var i, args=MM_goToURL.arguments; document.MM_returnValue = false;  for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location='"+args[i+1]+"'");}function YY_checkform() { //v4.71//copyright (c)1998,2002 Yaromat.com  var a=YY_checkform.arguments,oo=true,v='',s='',err=false,r,o,at,o1,t,i,j,ma,rx,cd,cm,cy,dte,at;  for (i=1; i<a.length;i=i+4){    if (a[i+1].charAt(0)=='#'){r=true; a[i+1]=a[i+1].substring(1);}else{r=false}    o=MM_findObj(a[i].replace(/\[\d+\]/ig,""));    o1=MM_findObj(a[i+1].replace(/\[\d+\]/ig,""));    v=o.value;t=a[i+2];    if (o.type=='text'||o.type=='password'||o.type=='hidden'){      if (r&&v.length==0){err=true}      if (v.length>0)      if (t==1){ //fromto        ma=a[i+1].split('_');if(isNaN(v)||v<ma[0]/1||v > ma[1]/1){err=true}      } else if (t==2){        rx=new RegExp("^[\\w\.=-]+@[\\w\\.-]+\\.[a-zA-Z]{2,4}$");if(!rx.test(v))err=true;      } else if (t==3){ // date        ma=a[i+1].split("#");at=v.match(ma[0]);        if(at){          cd=(at[ma[1]])?at[ma[1]]:1;cm=at[ma[2]]-1;cy=at[ma[3]];          dte=new Date(cy,cm,cd);          if(dte.getFullYear()!=cy||dte.getDate()!=cd||dte.getMonth()!=cm){err=true};        }else{err=true}      } else if (t==4){ // time        ma=a[i+1].split("#");at=v.match(ma[0]);if(!at){err=true}      } else if (t==5){ // check this 2            if(o1.length)o1=o1[a[i+1].replace(/(.*\[)|(\].*)/ig,"")];            if(!o1.checked){err=true}      } else if (t==6){ // the same            if(v!=MM_findObj(a[i+1]).value){err=true}      }    } else    if (!o.type&&o.length>0&&o[0].type=='radio'){          at = a[i].match(/(.*)\[(\d+)\].*/i);          o2=(o.length>1)?o[at[2]]:o;      if (t==1&&o2&&o2.checked&&o1&&o1.value.length/1==0){err=true}      if (t==2){        oo=false;        for(j=0;j<o.length;j++){oo=oo||o[j].checked}        if(!oo){s+='* '+a[i+3]+'\n'}      }    } else if (o.type=='checkbox'){      if((t==1&&o.checked==false)||(t==2&&o.checked&&o1&&o1.value.length/1==0)){err=true}    } else if (o.type=='select-one'||o.type=='select-multiple'){      if(t==1&&o.selectedIndex/1==0){err=true}    }else if (o.type=='textarea'){      if(v.length<a[i+1]){err=true}    }    if (err){s+='* '+a[i+3]+'\n'; err=false}  }  if (s!=''){alert('The required information is incomplete or contains errors:\t\t\t\t\t\n\n'+s)}  document.MM_returnValue = (s=='');}function MM_changeProp(objName,x,theProp,theValue) { //v6.0  var obj = MM_findObj(objName);  if (obj && (theProp.indexOf("style.")==-1 || obj.style)){    if (theValue == true || theValue == false)      eval("obj."+theProp+"="+theValue);    else eval("obj."+theProp+"='"+theValue+"'");  }}function WhereHear_OnClick(){	var website = MM_findObj("pnlWebsite");	if (!website) return;		var obj = MM_findObj("WhereHear");	if (obj)	{		switch (obj.value)		{			case "Website":			{				website.style.display = "block";				break;			}			default:			{				var whatWebsite = MM_findObj("WhereDetails");					if (whatWebsite)					whatWebsite.value = "";				website.style.display = "none";				break;			}		}			}}function cmbWhereDidYouHear_OnClick(){	var city = findObj("pnlCity");	if (!city) return;		var website = findObj("pnlWebsite");	if (!website) return;		var obj = findObj("cmbWhereDidYouHear");	if (obj)	{		switch (obj.value)		{			case "Television news story":			{				city.style.display = "block";				website.style.display = "none";				break;			}				case "Radio news story":			{				city.style.display = "block";				website.style.display = "none";				break;			}			case "Newspaper article":			{				city.style.display = "block";				website.style.display = "none";				break;			}			case "Internet":			{				city.style.display = "none";				website.style.display = "block";				break;			}			default:			{				var whereCity = findObj("txtWhereCity");				var whatWebsite = findObj("txtWhatWebsite");				if (whereCity)					whereCity.value = "";				city.style.display = "none";				if (whatWebsite)					whatWebsite.value = "";				website.style.display = "none";				break;			}		}			}}function MM_openBrWindow(theURL,winName,features) { //v2.0  window.open(theURL,winName,features);}//-->/*------------------------------------------------------------	Document Text Sizer- Copyright 2003 - Taewook Kang.  All rights reserved.	Coded by: Taewook Kang (txkang.REMOVETHIS@hotmail.com)	Web Site: http://txkang.com	Script featured on Dynamic Drive (http://www.dynamicdrive.com)		Please retain this copyright notice in the script.	License is granted to user to reuse this code on 	their own website if, and only if, 	this entire copyright notice is included.--------------------------------------------------------------*///Specify affected tags. Add or remove from list:var tgs = new Array( 'div','td','tr');//Specify spectrum of different font sizes:var szs = new Array( 'xx-small','x-small','small','medium','large','x-large','xx-large' );var startSz = 2;function ts( trgt,inc ) {	if (!document.getElementById) return	var d = document,cEl = null,sz = startSz,i,j,cTags;		sz += inc;	if ( sz < 0 ) sz = 0;	if ( sz > 6 ) sz = 6;	startSz = sz;			if ( !( cEl = d.getElementById( trgt ) ) ) cEl = d.getElementsByTagName( trgt )[ 0 ];	cEl.style.fontSize = szs[ sz ];	for ( i = 0 ; i < tgs.length ; i++ ) {		cTags = cEl.getElementsByTagName( tgs[ i ] );		for ( j = 0 ; j < cTags.length ; j++ ) cTags[ j ].style.fontSize = szs[ sz ];	}}function Disclaimer(){{ var Ok_Cancel= confirm("You are about to leave the NAABT,Inc. website. NAABT,Inc. provides links to other Internet sites as a service to its users, and is not responsible for the content of these external sites. NAABT,Inc., its employees, and contractors do not endorse, warrant, or guarantee the products, services, or information described or offered at these other Internet sites. Any reference to a commercial product, process, or service is not an endorsement or recommendation by NAABT,Inc., its employees, or contractors. NAABT,Inc.,  does not warrant or assume any legal liability or responsibility for the accuracy, completeness, or usefulness of any information, or other content on any website."); if (Ok_Cancel== true) {   window.location = "http://www.addictionsurvivors.org/vbulletin/forumdisplay.php?f\=45"; } else {  return false  }}}function fontsizeup(){	var active = getActiveStyleSheet();	switch (active)	{		case 'A--':			setActiveStyleSheet('A-');		break;		case 'A-':			setActiveStyleSheet('A');		break;		case 'A':			setActiveStyleSheet('A+');		break;		case 'A+':			setActiveStyleSheet('A++');		break;		case 'A++':			setActiveStyleSheet('A');		break;		default:			setActiveStyleSheet('A');		break;	}}function fontsizedown(){	active = getActiveStyleSheet();	switch (active)	{		case 'A++' : 			setActiveStyleSheet('A+');		break;		case 'A+' : 			setActiveStyleSheet('A');		break;		case 'A' : 			setActiveStyleSheet('A-');		break;		case 'A-' : 			setActiveStyleSheet('A--');		break;		case 'A--' : 		break;		default :			setActiveStyleSheet('A--');		break;	}}function setActiveStyleSheet(title){	var i, a, main;	for (i = 0; (a = document.getElementsByTagName('link')[i]); i++)	{		if (a.getAttribute('rel').indexOf('style') != -1 && a.getAttribute('title'))		{			a.disabled = true;			if (a.getAttribute('title') == title)			{				a.disabled = false;			}		}	}}function getActiveStyleSheet(){	var i, a;	for (i = 0; (a = document.getElementsByTagName('link')[i]); i++)	{		if (a.getAttribute('rel').indexOf('style') != -1 && a.getAttribute('title') && !a.disabled)		{			return a.getAttribute('title');		}	}	return null;}function getPreferredStyleSheet(){	return ('A-');}