<!--
function MM_goToURL() { //v3.0
  var i, args=MM_goToURL.arguments; document.MM_returnValue = false;
  for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location='"+args[i+1]+"'");
}
function ShowInfo(whichcontent){

if (document.all||document.getElementById){
cross_el=document.getElementById? document.getElementById("Descriptions"):document.all.Descriptions
if (whichcontent == "Titulo") {
cross_el.innerHTML='<br>Ingresa un título descriptivo para el casamiento.<br>Por ejemplo: Nos vamos a la India!'
}
else if (whichcontent == "Marido") {
cross_el.innerHTML='<br>Ingresa el primer nombre del marido.<br>Por ejemplo: Matías'
}
else if (whichcontent == "Mujer") {
cross_el.innerHTML='<br>Ingresa el primer nombre de la mujer.<br>Por ejemplo: Jimena'
}
else { 
cross_el.innerHTML=''
}
}
else if (document.layers){
document.d1.document.d2.document.write(''+whichcontent+'')
document.d1.document.d2.document.close()
}

}


function passwordChanged() {
var strength = document.getElementById('strength');
var strongRegex = new RegExp("^(?=.{8,})(?=.*[A-Z])(?=.*[a-z])(?=.*[0-9])(?=.*\\W).*$", "g");
var mediumRegex = new RegExp("^(?=.{7,})(((?=.*[A-Z])(?=.*[a-z]))|((?=.*[A-Z])(?=.*[0-9]))|((?=.*[a-z])(?=.*[0-9]))).*$", "g");
var enoughRegex = new RegExp("(?=.{6,}).*", "g");
var pwd = document.getElementById("Password");
if (pwd.value.length==0) {
strength.innerHTML = '';
} else if (false == enoughRegex.test(pwd.value)) {
strength.innerHTML = 'Muy corto';
} else if (strongRegex.test(pwd.value)) {
strength.innerHTML = '<span style="color:green">Seguro!</span>';
} else if (mediumRegex.test(pwd.value)) {
strength.innerHTML = '<span style="color:orange">Medio!</span>';
} else { 
strength.innerHTML = '<span style="color:red">Bajo!</span>';
}
}




function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}







function check_fields(){
   var field1 = document.getElementById('Password');
   var field2 = document.getElementById('Password2');

   if(field1.value !== field2.value){
        alert('Las contraseñas ingresadas no coinciden. Por favor intenta nuevamente!');
        return false;
   }else{
        return true;
   }
}



function Show(divId)
{
document.getElementById(divId).style.display = 'inline';
//(v).style.display = 'inline';
}
function Hide(divId)
{
document.getElementById(divId).style.display = 'none';
//(v).style.display = 'none';
}






function capitalizeMe(obj) {
val = obj.value;
newVal = '';
val = val.split(' ');
for(var c=0; c < val.length; c++) {
newVal += val[c].substring(0,1).toUpperCase() +
val[c].substring(1,val[c].length) + ' ';
}
obj.value = newVal;
}





<!--
function MM_validateForm() { //v4.0
  if (document.getElementById){
    var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
    for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=document.getElementById(args[i]);
      if (val) { nm=val.name; if ((val=val.value)!="") {
        if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
          if (p<1 || p==(val.length-1)) errors+='- '+nm+' debe contener una dirección de email válida.\n';
        } else if (test!='R') { num = parseFloat(val);
          if (isNaN(val)) errors+='- '+nm+' debe contener un número.\n';
          if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
            min=test.substring(8,p); max=test.substring(p+1);
            if (num<min || max<num) errors+='- '+nm+' debe contener un número entre '+min+' y '+max+'.\n';
      } } } else if (test.charAt(0) == 'R') errors += '- '+nm+' es obligatorio.\n'; }
    } if (errors) alert('Error:\n'+errors);
    document.MM_returnValue = (errors == '');
} }


function dis(obj)
{
 for(i=0;i<obj.length;i++)
  if(obj.elements[i].type == "submit" || obj.elements[i].type == "reset")
  {
  obj.elements[i].value = "Enviando...";
  obj.elements[i].disabled = 1;
  }
}




/***********************************************
* Pausing up-down scroller- © Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for this script and 100s more.
***********************************************/

function pausescroller(content, divId, divClass, delay){
this.content=content //message array content
this.tickerid=divId //ID of ticker div to display information
this.delay=delay //Delay between msg change, in miliseconds.
this.mouseoverBol=0 //Boolean to indicate whether mouse is currently over scroller (and pause it if it is)
this.hiddendivpointer=1 //index of message array for hidden div
document.write('<div id="'+divId+'" class="'+divClass+'" style="position: relative; overflow: hidden"><div class="innerDiv" style="position: absolute; width: 100%" id="'+divId+'1">'+content[0]+'</div><div class="innerDiv" style="position: absolute; width: 100%; visibility: hidden" id="'+divId+'2">'+content[1]+'</div></div>')
var scrollerinstance=this
if (window.addEventListener) //run onload in DOM2 browsers
window.addEventListener("load", function(){scrollerinstance.initialize()}, false)
else if (window.attachEvent) //run onload in IE5.5+
window.attachEvent("onload", function(){scrollerinstance.initialize()})
else if (document.getElementById) //if legacy DOM browsers, just start scroller after 0.5 sec
setTimeout(function(){scrollerinstance.initialize()}, 500)
}

// -------------------------------------------------------------------
// initialize()- Initialize scroller method.
// -Get div objects, set initial positions, start up down animation
// -------------------------------------------------------------------

pausescroller.prototype.initialize=function(){
this.tickerdiv=document.getElementById(this.tickerid)
this.visiblediv=document.getElementById(this.tickerid+"1")
this.hiddendiv=document.getElementById(this.tickerid+"2")
this.visibledivtop=parseInt(pausescroller.getCSSpadding(this.tickerdiv))
//set width of inner DIVs to outer DIV's width minus padding (padding assumed to be top padding x 2)
this.visiblediv.style.width=this.hiddendiv.style.width=this.tickerdiv.offsetWidth-(this.visibledivtop*2)+"px"
this.getinline(this.visiblediv, this.hiddendiv)
this.hiddendiv.style.visibility="visible"
var scrollerinstance=this
document.getElementById(this.tickerid).onmouseover=function(){scrollerinstance.mouseoverBol=1}
document.getElementById(this.tickerid).onmouseout=function(){scrollerinstance.mouseoverBol=0}
if (window.attachEvent) //Clean up loose references in IE
window.attachEvent("onunload", function(){scrollerinstance.tickerdiv.onmouseover=scrollerinstance.tickerdiv.onmouseout=null})
setTimeout(function(){scrollerinstance.animateup()}, this.delay)
}


// -------------------------------------------------------------------
// animateup()- Move the two inner divs of the scroller up and in sync
// -------------------------------------------------------------------

pausescroller.prototype.animateup=function(){
var scrollerinstance=this
if (parseInt(this.hiddendiv.style.top)>(this.visibledivtop+5)){
this.visiblediv.style.top=parseInt(this.visiblediv.style.top)-5+"px"
this.hiddendiv.style.top=parseInt(this.hiddendiv.style.top)-5+"px"
setTimeout(function(){scrollerinstance.animateup()}, 50)
}
else{
this.getinline(this.hiddendiv, this.visiblediv)
this.swapdivs()
setTimeout(function(){scrollerinstance.setmessage()}, this.delay)
}
}

// -------------------------------------------------------------------
// swapdivs()- Swap between which is the visible and which is the hidden div
// -------------------------------------------------------------------

pausescroller.prototype.swapdivs=function(){
var tempcontainer=this.visiblediv
this.visiblediv=this.hiddendiv
this.hiddendiv=tempcontainer
}

pausescroller.prototype.getinline=function(div1, div2){
div1.style.top=this.visibledivtop+"px"
div2.style.top=Math.max(div1.parentNode.offsetHeight, div1.offsetHeight)+"px"
}

// -------------------------------------------------------------------
// setmessage()- Populate the hidden div with the next message before it's visible
// -------------------------------------------------------------------

pausescroller.prototype.setmessage=function(){
var scrollerinstance=this
if (this.mouseoverBol==1) //if mouse is currently over scoller, do nothing (pause it)
setTimeout(function(){scrollerinstance.setmessage()}, 100)
else{
var i=this.hiddendivpointer
var ceiling=this.content.length
this.hiddendivpointer=(i+1>ceiling-1)? 0 : i+1
this.hiddendiv.innerHTML=this.content[this.hiddendivpointer]
this.animateup()
}
}

pausescroller.getCSSpadding=function(tickerobj){ //get CSS padding value, if any
if (tickerobj.currentStyle)
return tickerobj.currentStyle["paddingTop"]
else if (window.getComputedStyle) //if DOM2
return window.getComputedStyle(tickerobj, "").getPropertyValue("padding-top")
else
return 0
}
















var supportsKeys = false

function favChange(rnum) {
	f = document.newMsg;
	
	if (f.favs.selectedIndex >=0) {
		f.msgTo.value = f.favs.options[f.favs.selectedIndex].value
	}

	if (f.favs.selectedIndex > 0 && f.favs.selectedIndex <= rnum + 1) {
		f.Mensaje.focus();
	} else {
		f.msgTo.focus();
	}
}
function calcCharLeft(f) {
		lenUSig = f.lenSSig.value
		maxLength = 100 - f.lenSysSig.value - lenUSig
        if (f.Mensaje.value.length > maxLength) {
	        f.Mensaje.value = f.Mensaje.value.substring(0,maxLength)
		    charleft = 0
        } else {
			charleft = maxLength - f.Mensaje.value.length
		}

        f.msgCL.value = charleft
}

function textKey(f) {
	supportsKeys = true
	calcCharLeft(f)
}







function calc(a,b,c){
  one = a;
  two = b; 
	three = c;
	three1 = (three*1);
  three2 = Math.round(three1*Math.pow(10,2))/Math.pow(10,2);
  three3 = new String(""+three2+"");
  three4 = three3.replace(".",",");
  final = (one*1)+(two*1);
  final2 = Math.round(final*Math.pow(10,2))/Math.pow(10,2);
  final3 = new String(""+final2+"");
  final4 = final3.replace(".",",");
  document.frm.vTotalCostPesos.value = final4;
  document.frm.vTotalComision.value = three4;
  document.frm.TotalPesos.value = final4;

	//alert("comision: " + three4 + " - a: " + a + " - b: " + b + " - c: " + c + "/n" + " - three4: " + three4 + " - final4: " + final4 + "/n")
}
//-->
