
var agt=navigator.userAgent.toLowerCase();var is_major=parseInt(navigator.appVersion);var is_minor=parseFloat(navigator.appVersion);var is_ie=((agt.indexOf("msie")!=-1)&&(agt.indexOf("opera")==-1));var is_moz=((agt.indexOf("gecko")!=-1)&&(agt.indexOf("khtml")==-1));var is_khtml=(agt.indexOf("khtml")!=-1);var is_opera=(agt.indexOf("opera")!=-1);function select_nav(){var nav_links=document.getElementById('main-nav').getElementsByTagName('a');var selected=location.pathname;for(var i=0;i<nav_links.length;i++){var link=nav_links[i].pathname;if(link.substring(0,1)!='/')link='/'+link;if(link==selected){var section=link.substring(1,(link.length-5));rollOver(section);}}}
function rollOver(section){document.getElementById("n-"+section).src="images/n_"+section+"_o.gif";secondNav(section);}
function prettyDate(datestring,format){var output='';if(format=='mmddyyyy'){var theDate=datestring.split(" ");var pieces=theDate[0].split("-");output=pieces[1]+"\/"+pieces[2]+"\/"+pieces[0];}
return output;}
function popUpEmail(){var popUp=window.open('http://webhostdev/L10Apps/email_friend.php?refer=http://webhostdev/'+location.pathname,'emailWindow','width=420,height=400,location=no,menubar=no,scrollbars=no');return false;}
function printPage(){window.print();return false;}
function validate(){if(document.frmContactInfo.first_name.value.length==0){alert('First Name is required');document.frmContactInfo.first_name.focus();return false;}
if(document.frmContactInfo.last_name.value.length==0){alert('Last Name is required');document.frmContactInfo.last_name.focus();return false;}
if(document.frmContactInfo.first_name.value.length+document.frmContactInfo.last_name.value.length<4){alert("Your name does not appear to be valid.\nThe total length of your first name and last name must be at least 4 characters.\nPlease re-enter your first and/or last name.");document.frmContactInfo.first_name.select();document.frmContactInfo.first_name.focus();return false;}
if(!isNaN(document.frmContactInfo.first_name.value)){alert("Your first name cannot be a number");document.frmContactInfo.first_name.value="";document.frmContactInfo.first_name.focus();return false;}
if(!isNaN(document.frmContactInfo.last_name.value)){alert("Your last name cannot be a number");document.frmContactInfo.last_name.value="";document.frmContactInfo.last_name.focus();return false;}
if(document.frmContactInfo.phone.value.length==0){alert('A Phone Number is required');document.frmContactInfo.phone.focus();return false;}
if(document.frmContactInfo.phone.value.length<10){alert("Your phone # does not appear to be correct. Please enter a number that is at least 10 characters long, area code first.");document.frmContactInfo.phone.select();document.frmContactInfo.phone.focus();return false;}
if(document.frmContactInfo.phone.value=="1234567890"){alert("Your phone # does not appear to be correct\n\nPlease enter a number that is at least 10 characters long, \nis not equal to 1234567890 \nwith the area code first.");document.frmContactInfo.phone.select();document.frmContactInfo.phone.focus();return false;}
var phone=document.frmContactInfo.phone.value;phone=phone.replace(/\(/,'');phone=phone.replace(/\)/,'');phone=phone.replace(/-/g,'');phone=phone.replace(/\s/g,'');phone=phone.replace(/\./g,'');phone=phone.replace(/\+/,'');var ex=new RegExp(/^\d*\d+$/);if(!ex.test(phone)){alert("Invalid Phone Number. \n\nPlease re-enter, only the digits 0-9, a '+' for international,\na right and left paranthises '(,)' \na dash and/or a period are allowed.");document.frmContactInfo.phone.focus();return false;}
var emailID=document.frmContactInfo.email;if((emailID.value==null)||(emailID.value==""))
{alert("Please Enter your Email address");emailID.select();emailID.focus();return false;}
if(!check_email(emailID.value))
{alert("Please enter a valid email address.");emailID.select();emailID.focus();return false;}
var check_box_counter=0;check_box_counter=checkbox_counter();if(check_box_counter==0)
{alert("Please select an area of interest from the list.");return false;}
return ValidateForm();}
function checkbox_counter()
{var theForm=document.forms['frmContactInfo'];var form_element_length=theForm.length;var check_count=0;for(counter=0;counter<form_element_length;counter++)
{if(theForm.elements[counter].type=="checkbox")
{if(theForm.elements[counter].checked)
{check_count=check_count+1;}}}
return check_count;}
function checkPassword(){if(document.loginForm.user.value=="tsi"&&document.loginForm.pass.value=="pmp"){var LLSPage="http://webhostdev/project-management-training/Pmp-lunchtime-lecture-series-after.html";window.location=LLSPage;}else{alert("The username and passowrd you have entered are incorrect\nPlease try again using the username and password sent to you via email.");}}
function check_email(email)
{var reg1=/(@.*@)|(\.\.)|(@\.)|(\.@)|(^\.)/;var reg2=/^.+\@(\[?)[a-zA-Z0-9\-\.]+\.([a-zA-Z]{2,3}|[0-9]{1,3})(\]?)$/;if(!reg1.test(email)&&reg2.test(email))
{return true;}
return false;}
function webSTAT(){if((location.href.substr(0,6)=="https:")||(location.href.substr(0,6)=="HTTPS:")){document.write('<!-- BEGIN WebSTAT Activation Code -->'+'<script type="text/javascript" src="https://secure.webstat.com/cgi-bin/wsv2.cgi?42779"></script>'+'<noscript><a href="http://www.webstat.com"><img src="https://secure.webstat.com/scripts/wsb.php?ac=42779" border="0" alt="Site Metrics and Web Analytics by NextSTAT" /></a> </noscript>');}else{document.write('<!-- BEGIN WebSTAT Activation Code -->'+'<script type="text/javascript" src="http://hv3.webstat.com/cgi-bin/wsv2.cgi?42779"></script>'+'<noscript><a href="http://www.webstat.com"><img src="http://hv3.webstat.com/scripts/wsb.php?ac=42779" border="0" alt="Web Analytics and Web Statistics by NextSTAT" /></a> </noscript>');}}
function WebDex(){}
function WebDexThankYou(){}
function google_crosstracking()
{document.write('<!-- Google Code for default Conversion Page -->'+'<script language="JavaScript" type="text/javascript">'+'<!--'+'var google_conversion_type = \'landing\';'+'var google_conversion_id = 1069897088;'+'var google_conversion_language = "en_US";'+'var google_conversion_format = "1";'+'var google_conversion_color = "666666";'+'//-->'+'</script>'+'<script language="JavaScript" src="http://www.googleadservices.com/pagead/conversion.js">'+'</script>'+'<noscript>'+'<img height=1 width=1 border=0 src="http://www.googleadservices.com/pagead/conversion/1069897088/extclk?script=0">'+'</noscript>');}
function triolive_chat()
{document.write('<!-- TrioLive Chat Begin -->'+'<script>'+'var online_graphic = \'https://www.truesolutions.com/triolive/graphic.php?id=cc9d-3\'; '+'var offline_graphic = \'https://www.truesolutions.com/triolive/graphic.php?id=cd82-4\'; '+'var check_back = \'1\'; '+'</script>'+'<script src="https://www.truesolutions.com/triolive/visitor.php?code=ec0b8c&dept=2&type=image"></script>'+'<!-- TrioLive Chat End -->');}