<!--
function startWin(TheWindow,scrollBar,theWidth,theHeight)
{
var desktop=window.open(TheWindow,"_blank","toolbar=no,location=no,status=yes,menubar=no,scrollbars="+scrollBar+",width="+theWidth+",height="+theHeight+",resizable");
var screenwidth=screen.width
var screenheight=screen.height
var leftcoord=(screen.width-theWidth)/2
var topcoord=(screen.height-theHeight)/2
desktop.moveTo(leftcoord,topcoord);
}

function startPrintWin(TheWindow,scrollBar,theWidth,theHeight)
{
var desktop=window.open(TheWindow,"_blank","toolbar=no,location=no,status=no,menubar=yes,scrollbars="+scrollBar+",width="+theWidth+",height="+theHeight+",resizable");
var screenwidth=screen.width
var screenheight=screen.height
var leftcoord=(screen.width-theWidth)/2
var topcoord=(screen.height-theHeight-30)/2
desktop.moveTo(leftcoord,topcoord);
}

function startCalendarWin(TheWindow,scrollBar,theWidth,theHeight)
{
var desktop=window.open(TheWindow,"_blank","toolbar=no,location=no,status=yes,menubar=no,scrollbars=yes,width=600,height=400,resizable");
var screenwidth=screen.width
var screenheight=screen.height
var leftcoord=(screen.width-theWidth)/2
var topcoord=(screen.height-theHeight)/2
desktop.moveTo(leftcoord,topcoord);
}

function startWinGallery(TheWindow,scrollBar,theWidth,theHeight)
{
var desktop=window.open(TheWindow,"_blank","toolbar=no,location=no,status=no,menubar=no,scrollbars="+scrollBar+",width="+theWidth+",height="+theHeight+",noresize");
var screenwidth=screen.width
var screenheight=screen.height
var leftcoord=(screen.width-theWidth)/2
var topcoord=(screen.height-theHeight)/2
desktop.moveTo(leftcoord,topcoord);
}

function setFocus(theID,theOnColor)
{
eval("document.getElementById('"+theID+"').style.backgroundColor='" + theOnColor + "';");
}

function releaseFocus(theID,theOffColor)
{
eval("document.getElementById('"+theID+"').style.backgroundColor='" + theOffColor + "';");
}

function isGreaterThan(argInput, argMin)

{ if (argInput.length >= argMin)
        {return true;}
  else
        {return false;}
}

// ##############################################################

function validEmail(fld) {

  var invalidCharsList = " /:,;~#";
  var errorChar;
 
  if ((fld.value.indexOf('@',0)==-1) || (fld.value.indexOf('@',0)== 0) || (fld.value.indexOf('.',0)==-1)) {
    fld.select();
    fld.focus();
    return (false);
  }

  for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (fld.value.indexOf(errorChar,0) != -1) {
      fld.select();
      fld.focus();
      return (false);
    }
  }

  return (true);
}

// ##############################################################

function isEmailN(s) {

  invalidCharsList = " /:,;~#";
 
  if (s.value.indexOf('@',0)==-1 || s.value.indexOf('@',0)== 0 || s.value.indexOf('.',0)==-1) {
    s.select();
    s.focus();
    return (false);
  }
  for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (s.value.indexOf(errorChar,0) != -1) {
      s.select();
      s.focus();
      return (false);
    }
  }
    return (true);
}

// ##############################################################

function isEmail()

{
invalidCharsList = " /:,;~#";

if (document.theForm.email.value.indexOf('@',0)==-1 || document.theForm.email.value.indexOf('@',0)== 0 || document.theForm.email.value.indexOf('.',0)==-1)
        {
    document.theForm.email.select();
    document.theForm.email.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.email.value.indexOf(errorChar,0) != -1) {
    document.theForm.email.select();
    document.theForm.email.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmailFriend()

{
invalidCharsList = " /:,;~#";

if (document.theForm.friend_email.value.indexOf('@',0)==-1 || document.theForm.friend_email.value.indexOf('@',0)== 0 || document.theForm.friend_email.value.indexOf('.',0)==-1)
        {
    document.theForm.friend_email.select();
    document.theForm.friend_email.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.friend_email.value.indexOf(errorChar,0) != -1) {
    document.theForm.friend_email.select();
    document.theForm.friend_email.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmail_1()

{
invalidCharsList = " /:,;~#";

if (document.theForm.emailaddr_1.value.indexOf('@',0)==-1 || document.theForm.emailaddr_1.value.indexOf('@',0)== 0 || document.theForm.emailaddr_1.value.indexOf('.',0)==-1)
        {
    document.theForm.emailaddr_1.select();
    document.theForm.emailaddr_1.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.emailaddr_1.value.indexOf(errorChar,0) != -1) {
    document.theForm.emailaddr_1.select();
    document.theForm.emailaddr_1.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmail_2()

{
invalidCharsList = " /:,;~#";

if (document.theForm.emailaddr_2.value.indexOf('@',0)==-1 || document.theForm.emailaddr_2.value.indexOf('@',0)== 0 || document.theForm.emailaddr_2.value.indexOf('.',0)==-1)
        {
    document.theForm.emailaddr_2.select();
    document.theForm.emailaddr_2.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.emailaddr_2.value.indexOf(errorChar,0) != -1) {
    document.theForm.emailaddr_2.select();
    document.theForm.emailaddr_2.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmail1()

{
invalidCharsList = " /:,;~#";

if (document.theForm.ref1_email.value.indexOf('@',0)==-1 || document.theForm.ref1_email.value.indexOf('@',0)== 0 || document.theForm.ref1_email.value.indexOf('.',0)==-1)
        {
    document.theForm.ref1_email.select();
    document.theForm.ref1_email.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.ref1_email.value.indexOf(errorChar,0) != -1) {
    document.theForm.ref1_email.select();
    document.theForm.ref1_email.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmail2()

{
invalidCharsList = " /:,;~#";

if (document.theForm.ref2_email.value.indexOf('@',0)==-1 || document.theForm.ref2_email.value.indexOf('@',0)== 0 || document.theForm.ref2_email.value.indexOf('.',0)==-1)
        {
    document.theForm.ref2_email.select();
    document.theForm.ref2_email.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.ref2_email.value.indexOf(errorChar,0) != -1) {
    document.theForm.ref2_email.select();
    document.theForm.ref2_email.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmail3()

{
invalidCharsList = " /:,;~#";

if (document.theForm.ref3_email.value.indexOf('@',0)==-1 || document.theForm.ref3_email.value.indexOf('@',0)== 0 || document.theForm.ref3_email.value.indexOf('.',0)==-1)
        {
    document.theForm.ref3_email.select();
    document.theForm.ref3_email.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.ref3_email.value.indexOf(errorChar,0) != -1) {
    document.theForm.ref3_email.select();
    document.theForm.ref3_email.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmail4()

{
invalidCharsList = " /:,;~#";

if (document.theForm.ref4_email.value.indexOf('@',0)==-1 || document.theForm.ref4_email.value.indexOf('@',0)== 0 || document.theForm.ref4_email.value.indexOf('.',0)==-1)
        {
    document.theForm.ref4_email.select();
    document.theForm.ref4_email.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.ref4_email.value.indexOf(errorChar,0) != -1) {
    document.theForm.ref4_email.select();
    document.theForm.ref4_email.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function isEmail5()

{
invalidCharsList = " /:,;~#";

if (document.theForm.ref5_email.value.indexOf('@',0)==-1 || document.theForm.ref5_email.value.indexOf('@',0)== 0 || document.theForm.ref5_email.value.indexOf('.',0)==-1)
        {
    document.theForm.ref5_email.select();
    document.theForm.ref5_email.focus();
    return (false);
     }
    for (i = 0; i < invalidCharsList.length; i++) {
    errorChar = invalidCharsList.charAt(i);
    if (document.theForm.ref5_email.value.indexOf(errorChar,0) != -1) {
    document.theForm.ref5_email.select();
    document.theForm.ref5_email.focus();
    return (false);
    }
}
    return (true);
}

// ##############################################################

function round(num)
{
    return Math.round(num*Math.pow(10,2))/Math.pow(10,2);
}

function FormatMoney(num)
{
        if (isNaN(parseInt(num))) return "NaN";

        var tmpNum = num;
        var iSign = num < 0 ? -1 : 1;           // Get sign of number
 
        // Adjust number so only the specified number of numbers after
        // the decimal point are shown.
        tmpNum *= 100;
        tmpNum = Math.round(Math.abs(tmpNum))
        tmpNum /= 100;
        tmpNum *= iSign;                                        // Readjust for sign
 
        // Create a string object to do our formatting on
        var tmpNumStr = new String(tmpNum);
 
        var iStart = tmpNumStr.indexOf(".");
        if (iStart < 0)
          tmpNumStr += ".00";
        else
          if ((tmpNumStr.length - iStart) == 2) tmpNumStr += "0";

        return tmpNumStr;               // Return our formatted string!
}

// ##############################################################

function isEmpty(s)
{
        if ((s == null) || (s.length == 0) || (s == '' ))
                { return true;
                }
        else
                { return false;
                }
}

// ##############################################################

function isDigit (c)
{   return ((c >= "0") && (c <= "9"))
}

// ##############################################################

function isTelephoneDigit (c)
{   return (((c >= "0") && (c <= "9")) || (c == " ") || (c == "(") || (c == ")") || (c == "-"))
}

// ##############################################################

function isMoneyDigit (c)
{   return (((c >= "0") && (c <= "9")) || (c == "R") || (c == " ") || (c == ",") || (c == "."))}

// ##############################################################

function isNumeric (argInput)

{   var i;
    for (i = 0; i < argInput.length; i++)
    {
        var c = argInput.charAt(i);
        if (!isDigit(c)) return false;
    }
    return true;
}

// ##############################################################

function isID(argInput)

{   var i;
    for (i = 0; i < argInput.length; i++)
    {
        var c = argInput.charAt(i);
        if (!isDigit(c)) return false;
    }
    return true;
}

// ##############################################################

function isMoney (argInput)

{   var i;
    for (i = 0; i < argInput.length; i++)
    {
        var c = argInput.charAt(i);
        if (!isMoneyDigit(c)) return false;
    }
    return true;
}

// ##############################################################

function isTelephone (argInput)

{   var i;
    for (i = 0; i < argInput.length; i++)
    {
        var c = argInput.charAt(i);
        if (!isTelephoneDigit(c)) return false;
    }
    return true;
}

// ##############################################################

function isCellphone (argInput)

{   var i;
    for (i = 0; i < argInput.length; i++)
    {
        var c = argInput.charAt(i);
        if (!isDigit(c)) return false;
    }

    return true;
}


// ##############################################################
// ##############################################################

function disableButton()
{
document.theForm.submitbutton.disabled=false;
}

// ##############################################################
// ##############################################################

<!-- Original:  Sandeep V. Tamhankar (stamhankar@hotmail.com) -->

<!-- This script and many more are available free online at -->
<!-- The JavaScript Source!! http://javascript.internet.com -->

<!-- Begin
function isValidDate(dateStr,blnID) {
// Vadi-Start : below lines are added to convert the date in to the required format
   if (isEmpty(dateStr)) {return true}
   if (blnID) dateStr = dateStr.substr(2, 2) + '/' + dateStr.substr(4, 2) + '/' + dateStr.substr(0, 2)
// Vadi-End

// Checks for the following valid date formats:
// MM/DD/YY   MM/DD/YYYY   MM-DD-YY   MM-DD-YYYY
// Also separates date into month, day, and year variables

var datePat = /^(\d{1,2})(\/|-)(\d{1,2})\2(\d{2}|\d{4})$/;

// To require a 4 digit year entry, use this line instead:
// var datePat = /^(\d{1,2})(\/|-)(\d{1,2})\2(\d{4})$/;

var matchArray = dateStr.match(datePat); // is the format ok?
if (matchArray == null) {
alert("Date is not in a valid format.")
return false;
}
month = matchArray[1]; // parse date into variables
day = matchArray[3];
year = matchArray[4];
if (month < 1 || month > 12) { // check month range
alert("Date Format : Month must be between 1 and 12.");
return false;
}
if (day < 1 || day > 31) {
alert("Date Format : Day must be between 1 and 31.");
return false;
}
if ((month==4 || month==6 || month==9 || month==11) && day==31) {
alert("Date Format : "+"Month "+month+" doesn't have 31 days!")
return false
}
if (month == 2) { // check for february 29th
var isleap = (year % 4 == 0 && (year % 100 != 0 || year % 400 == 0));
if (day>29 || (day==29 && !isleap)) {
alert("Date Format"+"February " + year + " doesn't have " + day + " days!");
return false;
   }
}
return true;  // date is valid
}
//  End -->

// ##############################################################
// ##############################################################

function isValidTime(timeStr) {
   if (isEmpty(timeStr)) {return true}

var timePat = /^(\d{2})(:)(\d{2})$/;

var matchArray = timeStr.match(timePat); // is the format ok?
if (matchArray == null) {
return false;
}
hour = matchArray[1]; // parse time into variables
minute = matchArray[3];
if (hour < 0 || hour > 23) { // check hour range
alert("Time Format : Hour must be between 0 and 23.");
return false;
}
if (minute < '00' || minute > '59') {
alert("Date Format : Minute must be between 0 and 59.");
return false;
}
return true;  // time is valid
}

// ##############################################################
// ##############################################################

function addMember()
{
if (isEmpty(document.theForm.firstname.value))
        { alert('Please specify your first name.');
        document.theForm.firstname.focus();
        return false;}
 
else if (isEmpty(document.theForm.surname.value))
        { alert('Please specify your surname.');
        document.theForm.surname.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else if ((!isEmpty(document.theForm.cellphone.value)) && ((!isNumeric(document.theForm.cellphone.value)) || (document.theForm.cellphone.value.length!==10)))
        { alert('Please specify a valid cellphone number.');
        document.theForm.cellphone.focus();
        return false;}
 
else if ((isEmpty(document.theForm.telephone.value)) && (isEmpty(document.theForm.cellphone.value)))
        { alert('Please specify either a contact telephone number or cellphone number.');
        document.theForm.cellphone.focus();
        return false;}
 
else if (document.theForm.residence.selectedIndex==0)
        { alert('Please specify your city of residence.');
        document.theForm.residence.focus();
        return false;}
 
else if (isEmpty(document.theForm.username.value))
        { alert('Please specify a username. We recommend using your a-mail address as your username.');
        document.theForm.username.focus();
        return false;}
 
else if (isEmpty(document.theForm.password.value))
        { alert('Please specify a password.');
        document.theForm.password.focus();
        return false;}
 
else if (isEmpty(document.theForm.password1.value))
        { alert('Please confirm your password.');
        document.theForm.password1.focus();
        return false;}

else if (document.theForm.password.value !== document.theForm.password1.value)
        { alert('Your password confirmation does not match your password. Please try again.');
        document.theForm.password1.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function updateMember()
{
if (isEmpty(document.theForm.firstname.value))
        { alert('Please specify your first name.');
        document.theForm.firstname.focus();
        return false;}
 
else if (isEmpty(document.theForm.surname.value))
        { alert('Please specify your surname.');
        document.theForm.surname.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else if ((!isEmpty(document.theForm.cellphone.value)) && ((!isNumeric(document.theForm.cellphone.value)) || (document.theForm.cellphone.value.length!==10)))
        { alert('Please specify a valid cellphone number.');
        document.theForm.cellphone.focus();
        return false;}
 
else if ((isEmpty(document.theForm.telephone.value)) && (isEmpty(document.theForm.cellphone.value)))
        { alert('Please specify either a contact telephone number or cellphone number.');
        document.theForm.cellphone.focus();
        return false;}
 
else if (document.theForm.residence.selectedIndex==0)
        { alert('Please specify your city of residence.');
        document.theForm.residence.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function updatePassword()
{
if (isEmpty(document.theForm.password.value))
        { alert('Please specify your new password.');
        document.theForm.password.focus();
        return false;}
 
else if (isEmpty(document.theForm.password1.value))
        { alert('Please confirm your new password.');
        document.theForm.password1.focus();
        return false;}

else if (document.theForm.password.value !== document.theForm.password1.value)
        { alert('Your password confirmation does not match your password. Please try again.');
        document.theForm.password1.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function sendReminder()
{
if (isEmpty(document.theForm.username.value))
        { alert('Please specify your username.');
        document.theForm.username.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function sendFeedback()
{
if (isEmpty(document.theForm.fullname.value))
        { alert('Please specify your full name.');
        document.theForm.fullname.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else if (isEmpty(document.theForm.cell.value))
        { alert('Please specify your phone number.');
        document.theForm.cell.focus();
        return false;}
 
else if (document.theForm.feedback.selectedIndex==0)
        { alert('Please specify your feedback type.');
        document.theForm.feedback.focus();
        return false;}
 
else if (isEmpty(document.theForm.comments.value))
        { alert('Please specify your comments.');
        document.theForm.comments.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function sendCard()
{
if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
  { alert('Please specify a valid e-mail address.');
  document.theForm.email.focus();
  return false;}
 
else
  return true;
}

// ##############################################################
// ##############################################################

function requestAd()
{
if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
  { alert('Please specify a valid e-mail address.');
  document.theForm.email.focus();
  return false;}

else if (isEmpty(document.theForm.Company.value))
  { alert('Please specify your company\'s name.');
  document.theForm.Company.focus();
  return false;}
 
else if (isEmpty(document.theForm.Name.value))
  { alert('Please specify your name.');
  document.theForm.Name.focus();
  return false;}
 
else if (document.theForm.Terms.checked==false)
  { alert('Please confirm that you agree to the terms of our advertising policy.');
  document.theForm.Terms.focus();
  return false;}
 
else
  return true;
}

// ##############################################################
// ##############################################################

function sendCallMe()
{
if (isEmpty(document.theForm.fullname.value))
        { alert('Please specify your full name.');
        document.theForm.fullname.focus();
        return false;}
 
else if (isEmpty(document.theForm.telephone.value))
        { alert('Please specify your contact telephone number.');
        document.theForm.telephone.focus();
        return false;}
 
else if (isEmpty(document.theForm.comments.value))
        { alert('Please specify your comments.');
        document.theForm.comments.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function sendGuestbook()
{
if (isEmpty(document.theForm.comments.value))
        { alert('Please specify your comments.');
        document.theForm.comments.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function bookStudio()
{
if (isEmpty(document.theForm.firstname.value))
        { alert('Please specify your first name.');
        document.theForm.firstname.focus();
        return false;}
 
else if (isEmpty(document.theForm.surname.value))
        { alert('Please specify your surname.');
        document.theForm.surname.focus();
        return false;}
 
else if ((!isNumeric(document.theForm.telephone.value)) || (isEmpty(document.theForm.telephone.value) || (document.theForm.telephone.value.length!==10)))
        { alert('Please specify your cellphone number.');
        document.theForm.telephone.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function bookTraining()
{
if (isEmpty(document.theForm.firstname.value))
        { alert('Please specify your first name.');
        document.theForm.firstname.focus();
        return false;}
 
else if (isEmpty(document.theForm.surname.value))
        { alert('Please specify your surname.');
        document.theForm.surname.focus();
        return false;}
 
else if ((!isNumeric(document.theForm.telephone.value)) || (isEmpty(document.theForm.telephone.value) || (document.theForm.telephone.value.length!==10)))
        { alert('Please specify your cellphone number.');
        document.theForm.telephone.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function validateSpeaker() {

if (document.theForm.cancel_confirm.checked==false)
        { alert('Please confirm that you agree to the terms and conditions.');
        document.theForm.cancel_confirm.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function validateRequest() {

var it = 0;

if (isEmpty(document.theForm.name.value))
        { alert('Please specify your name.');
        document.theForm.name.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify a valid e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else if (isEmpty(document.theForm.address.value))
        { alert('Please specify the address of the venue.');
        document.theForm.address.focus();
        return false;}
 
else if (isEmpty(document.theForm.city.value))
        { alert('Please specify the city.');
        document.theForm.city.focus();
        return false;}
 
else if (isEmpty(document.theForm.event_date.value))
        { alert('Please specify the date of the event.');
        document.theForm.event_date.focus();
        return false;}
 
else if (isEmpty(document.theForm.est_attend.value))
        { alert('Please specify the estimated attendance.');
        document.theForm.est_attend.focus();
        return false;}
 
else
        {
        for (i=0;i<document.theForm.topic.length;i++) {
                if (document.theForm.topic[i].checked==true) {
                        it++;
                        break;
                }
        }
        if (it == 0)
                { alert('Please select at least one topic.');
                document.theForm.topic[0].focus();
                return false;}

        else if (isEmpty(document.theForm.theme.value))
                { alert('Please specify theme or purpose.');
                document.theForm.theme.focus();
                return false;}
 
        else if (isEmpty(document.theForm.addl_info.value))
                { alert('Please specify additional information.');
                document.theForm.addl_info.focus();
                return false;}
 
        else
                {
                return true;
                }
        }
}

// ##############################################################
// ##############################################################

function validateRating() {

if (isEmpty(document.theForm.event_date.value))
        { alert('Please specify the date of the presentation.');
        document.theForm.event_date.focus();
        return false;}
 
else if ((!isEmpty(document.theForm.email.value)) && (!isEmail(document.theForm.email.value)))
        { alert('Please specify a valid e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else if (isEmpty(document.theForm.organisation.value))
        { alert('Please specify the organisation who engaged the speaker.');
        document.theForm.organisation.focus();
        return false;}

else if ((isEmpty(document.theForm.SpeechTitle.value)) && (document.theForm.SpeechID.selectedIndex == document.theForm.SpeechID.length))
        { alert('Please specify the title of the speech that was delivered.');
        document.theForm.SpeechID.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function sendEnquiry()
{
if (isEmpty(document.theForm.firstname.value) && isEmpty(document.theForm.surname.value))
        { alert('Please specify your name.');
        document.theForm.firstname.focus();
        return false;}
 
else if ((isEmpty(document.theForm.emailaddr.value)) || (!isEmailN(document.theForm.emailaddr)))
        { alert('Please specify a valid e-mail address.');
        document.theForm.friend_email.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function sendEmailTofriend()
{
if (isEmpty(document.theForm.friend_name.value))
        { alert('Please specify your friend\'s name.');
        document.theForm.friend_name.focus();
        return false;}
 
else if ((isEmpty(document.theForm.friend_email.value)) || (!isEmailN(document.theForm.friend_email)))
        { alert('Please specify your friend\'s e-mail address.');
        document.theForm.friend_email.focus();
        return false;}
 
else if (isEmpty(document.theForm.sender.value))
        { alert('Please specify your name.');
        document.theForm.sender.focus();
        return false;}
 
else if ((isEmpty(document.theForm.emailaddr.value)) || (!isEmailN(document.theForm.emailaddr)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function addEvent()
{
if (isEmpty(document.theForm.fullname.value))
        { alert('Please specify your name.');
        document.theForm.fullname.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else if (isEmpty(document.theForm.eventname.value))
        { alert('Please specify the event name.');
        document.theForm.eventname.focus();
        return false;}
 
else if (isEmpty(document.theForm.eventvenue.value))
        { alert('Please specify the event venue.');
        document.theForm.eventvenue.focus();
        return false;}
 
else if (isEmpty(document.theForm.event_date.value))
        { alert('Please specify the event date.');
        document.theForm.event_date.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function addLink()
{
if (isEmpty(document.theForm.Requester.value))
        { alert('Please specify your name.');
        document.theForm.Requester.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify your e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else if (isEmpty(document.theForm.Name.value))
        { alert('Please specify the site name.');
        document.theForm.Name.focus();
        return false;}
 
else if (isEmpty(document.theForm.URL[1].value))
        { alert('Please specify the site URL.');
        document.theForm.URL[1].focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function addManual()
{
if (isEmpty(document.theForm.Fullname.value))
        { alert('Please specify your name.');
        document.theForm.Fullname.focus();
        return false;}
 
else if ((isEmpty(document.theForm.email.value)) || (!validEmail(document.theForm.email)))
        { alert('Please specify a valid e-mail address.');
        document.theForm.email.focus();
        return false;}
 
else
        {
        return true;
        }
}

// ##############################################################
// ##############################################################

function validatefeedbackform()
{
if (isEmpty(document.theForm.firstname.value))
        { alert('Please specify the first name.');
        document.theForm.firstname.focus();
        return false;}

else if (isEmpty(document.theForm.surname.value))
        { alert('Please specify the surname.');
        document.theForm.surname.focus();
        return false;}

else if ((isEmpty(document.theForm.email.value)) || (!isEmail(document.theForm.email.value)))
        { alert('Please specify a valid e-mail address');
        document.theForm.email.focus();
        return false;}

else if (isEmpty(document.theForm.comments.value))
        { alert('Please enter comments');
        document.theForm.comments.focus();
        return false;}
else
        {
        return true;
        }
}

//-->