function getParameter(paramName) {
  var searchString = window.location.search.substring(1),
      i, val, params = searchString.split("&");

  for (i=0;i<params.length;i++) {
    val = params[i].split("=");
    if (val[0] == paramName) {
      return unescape(val[1]);
    }
  }
  return null;
}

function respuesta(){
	location="#header";
	jQuery(".post").fadeOut("slow",function(){
		jQuery("div#gracias").fadeIn("slow");
	});
}

function preparar_respuesta(fuente){
	jQuery(".post").before("<div style='display: none;' id='gracias'></div>");
	jQuery("div#gracias").load(fuente);
}

function procesando(){
	jQuery("div#contact_form").hide("slow",function(){
		jQuery("div#procesando").fadeIn("slow");
	});
}

function procesando_out(){
	jQuery("div#contact_form").show("slow", function(){
		jQuery("div#procesando").hide("slow");
	});	
}

jQuery(document).ready(function($) {
	
	$("div#contact_form").before("<div style='display: none;' id='procesando'><h3><img src='/serviciosphp/contactforms/ajax-loader.gif' /> Procesando ...</h3></div>");
	
});
