function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}



rightClickWarning = "All images in this website copyrighted by Panna Foto Institute. All rights reserved. The images and/or text may not be copied, transmitted, published, reproduced or used in any way without written permission.";

displaySmugPopular = false;
<!--SM.PhotoBar.config.position = 'bottom';-->




function openLinkWindow(URL)
  {
   linkWindow=window.open(URL,"linkInfo","width=1200,height=1100,dependent=yes,resizable=no,scrollbars=yes,toolbar=no,menubar=no");
    linkWindow.focus();
   
  } 

function ContactFormValidate()
{
	if (document.ContactForm.firstname.value == "")
	{
		alert("Your First Name is required");
		document.ContactForm.firstname.focus();
		return false;

	}
	if (document.ContactForm.lastname.value == "")
	{
		alert("Your Last Name is required");
		document.ContactForm.lastname.focus();
		return false;

	}
      if (document.ContactForm.address1.value == "")
	{
		alert("Your Address is required");
		document.ContactForm.address1.focus();
		return false;
	}
        if (document.ContactForm.city.value == "")
	{
		alert("Your City is required");
		document.ContactForm.city.focus();
		return false;
	}
	  if (document.ContactForm.zipcode.value == "")
	{
		alert("Your Zip Code is required");
		document.ContactForm.zipcode.focus();
		return false;
	}
	  if (document.ContactForm.homephone1.value == "")
	{
		alert("Your Primary Home Phone is required (or enter 0)");
		document.ContactForm.homephone1.focus();
		return false;
	}
	  if (document.ContactForm.cellphone1.value == "")
	{
		alert("Your Primary Cell Phone is required (or enter 0)");
		document.ContactForm.cellphone1.focus();
		return false;
	}
	  if (document.ContactForm.email1.value == "")
	{
		alert("Your E-Mail Address is required");
		document.ContactForm.email1.focus();
		return false;
	}
	  if (document.ContactForm.email2.value == "")
	{
		alert("Your E-Mail Address is required");
		document.ContactForm.email2.focus();
		return false;
	}
	
            if (document.ContactForm.workshop.value == "")
	{
		alert("The Workshop/Event you are enrolling for is required");
		document.ContactForm.workshop.focus();
		return false;
	}

	  if (document.ContactForm.cameratype.value == "")
	{
		alert("Your Camera Type is required");
		document.ContactForm.cameratype.focus();
		return false;
	}
}


function swapBoxes() {
   box1 = YD.get("subcategoriesBox");
   box2 = YD.get("galleriesBox");
   if (box1 && box2)
   {
      swap = box1.innerHTML;
      box1.innerHTML = box2.innerHTML;
      box2.innerHTML = swap;
   }
}

