$(document).ready(function(){
	//content columns equal height
	/*if(jQuery('#leftColumn, #rightColumn')[0]){
		jQuery('#leftColumn, #rightColumn').equalHeight();
	}*/
	
	if(jQuery('#thisSubPage')[0]){
		jQuery('#thisSubPage').parent().parent().removeAttr('id');
	}
	/*
	//MSIE table header rotation
	if ($.browser.msie){
		$('.order .canv').each(function(){
			//this.style.filter = "progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";
			//this.style.whiteSpace = "pre";
			//this.height = '20px';
		});
	}
	
	if ($.browser.safari || $.browser.chrome){
		//$('.obj').css({ marginBottom: '-40px'})
	}*/
	
	
	//text hints
	if(jQuery('input')[0]){
		$('input').hint();
	}
	
	//table zebra
	if(jQuery('table.tabular')[0]){
		$('table.tabular tr:odd td').css({"background-color":"#fff"});
		$('table.tabular.impar tr:even td').css({"background-color":"#fff"});
		$('table.tabular.impar tr:odd td').css({"background-color":"transparent"});
	}
	
	//Hide div w/id other_documents
   jQuery("#other_documents").css("display","none");
   jQuery("#show_more").click(function(){

    if (jQuery("#show_more").is(":checked")){
        jQuery("#other_documents").show("fast");
    }
    else{     
        jQuery("#other_documents").hide("fast");
    }
  });
  
   jQuery("#required_export_5").click(function(){

    if (jQuery("#required_export_5").is(":checked")){
        jQuery("#other_documents").show("fast");
    }
    else{     
        jQuery("#other_documents").hide("fast");
    }
  });
  
  
  
  //Validation
  jQuery("#registrationForm").validate();
  
  jQuery('.inpQ').numeric();

});

function integerInput(e,inputElement)
{
    var keynum
    var keychar
    var numcheck
    if(window.event) // IE
    {
        keynum = e.keyCode
    }
    else if(e.which) // Netscape/Firefox/Opera
    {
        keynum = e.which
    }
    keychar = String.fromCharCode(keynum)
    re = new RegExp('[a-zA-Z0-9\.]');
    if(!keychar.match(re) && keynum != 8 && keynum != null) return false;
    return true;
}
