

function openWindow(href,width,height) {
	
	window.name = 'main_window1';
	
	xposition=70; yposition=40;
	if ((parseInt(navigator.appVersion) >= 4 )){
		xposition = (screen.width - width) / 2;
		yposition = (screen.height - height) / 2;
	} 
	args = "width=" + width + "," 
		    + "height=" + height + "," 
			+ "location=0," 
			+ "menubar=0,"
			+ "resizable=0,"
			+ "scrollbars=yes,"
			+ "status=yes," 
			+ "titlebar=0,"
			+ "toolbar=0,"
			+ "hotkeys=0,"
			+ "screenx=" + xposition + ","  //NN Only
			+ "screeny=" + yposition + ","  //NN Only
			+ "left=" + xposition + ","     //IE Only
			+ "top=" + yposition;           //IE Only 
	
    popup = window.open(href, '', args);
    popup.focus();
}

function selectedSite()
{
  if (document.registerSiteForm.selected.checked)
   {
      document.registerSiteForm.valid.disabled = false;
      document.registerSiteForm.foto.disabled = false;
   }
   else
   {
      document.registerSiteForm.valid.disabled = true;
      document.registerSiteForm.foto.disabled = true;
   }
}

function selectCheck(arg)
         {
          if (arg == 0)
          {	   
            if (document.forms.registerSiteForm.cat1.length == 0)
             {
                 document.forms.registerSiteForm.cat1.disabled = true;
		 document.forms.registerSiteForm.cat2.disabled = true;
             }
             else
             { 
               document.forms.registerSiteForm.cat1.disabled = false;	
             }
          }


	  if (arg == 1)
          { 
			
           if (document.forms.registerSiteForm.cat2.length == 0)
             {		
                 document.forms.registerSiteForm.cat2.disabled = true;
             }
             else
             {		
                document.forms.registerSiteForm.cat2.disabled = false;
             }
          }
         }


function selectCheck1(arg)
         {
          if (arg == 0)
          {
            if (document.forms.searchForm.cat1.length == 0)
             {
                 document.forms.searchForm.cat1.disabled = true;
		 document.forms.searchForm.cat2.disabled = true;
             }
             else
             {
               document.forms.searchForm.cat1.disabled = false;
             }
          }


	  if (arg == 1)
          {

           if (document.forms.searchForm.cat2.length == 0)
             {
                 document.forms.searchForm.cat2.disabled = true;
             }
             else
             {
                document.forms.searchForm.cat2.disabled = false;
             }
          }
         }
