 
			
				19/06/2014, 10:46
			
			
			     |  
      |    |    |    Fecha de Ingreso: junio-2009  
						Mensajes: 11
					  Antigüedad: 16 años, 5 meses Puntos: 0     |        |  
  |      Respuesta: Pasar informacion de un boton JavaScript        <body> 
		<div style=" width: 200px; height:600">    
        <form id="HtmlForm" action="http://localhost/Evolution/WebChat/WebChat.aspx" method="GET" target="formresult" onLoad = "resolucion (0.30)"; "calcHash">     
            <div> 
                <h1 font size = 100 style="text-align: center"><img src="Emoticons/iAgent.ico" alt=""/>EvoCHAT</h1> 
                <h2 style="text-align: center">Ingrese sus datos para inciar un chat con un agente.</h2> 
            </div>   
            <div style="width: 90%; margin: auto">   
                <div>   
                    <p><br /> 
                   <!-- Tema: -->   
                   <select name="theme" disabled="disabled" id="theme" style="visibility:hidden" > 
                     <option value="Default">Default</option> 
                     <option value="Blue">Blue</option> 
                   </select> 
                    <br/>Nombre / Alias : <input type ="text" id="username" name="username" value="" /> 
					 <br/>Email : <input id="email" name="email" value="" class=''  size='30' maxlength='100' title='direccion de correo'    /> 
					<br/> 
					<!--DN Estrategia:--> 
					Motivo de la consulta:</p> 
                    <p> 
					  <textarea id="lb_consulta" name="consulta"  rows ="10" cols="40"  value="" class='' type="text" size='60' maxlength='400' title='consulta' /> Escribre aqui tus comentarios</textarea>  
                    </p>   
                    <p> 
					<div id="x" style="display:none;"> 
					<input id="strategy" name="strategy" value="" style="visibility:hidden"   /> 
                      <br /><!-- Salted Hash:  --><input id="hash" name="hash" value="" style="visibility:hidden; width: 350px;" />  
					  <input type="button" disabled="disabled" style="visibility:hidden" onclick="calcHash()" value="Calcular hash MD5" /> 
					</div>   
                    </p>   
                </div>   
                <br/>   
                <div> 
                    <button onclick="FormSubmit();" style="width: 200px; height: 50px;">Conectar a WebChat</button> 
                </div>   
            </div>   
        </form>   
        <div style="width: 90%; margin: auto">   
            <br/> 
            <!--HashSecret: --> 
            <input name="hashsecret" disabled="disabled" style= "visibility:hidden" id="hashsecret" value="abcde" /> 
            <p>  
                </p> 
            <p style="font-size: small"> 
                <strong>NOTA:</strong> Este ejemplo asume que Evolution  
                WebChat y el servidor Evolution están alojados en el mismo servidor.  En  
                caso de estar alojados en máquinas distintas será necesario modificar el código  
                de esta página de ejemplo para reemplazar  
                'localhost' por la dirección pública del servidor WebChat.</p>   
        </div>   
    </body>   
    <script>   
        function calcHash() {   
            var textPlain = 'theme=' + $('#theme').val() + '&username=' + $('#username').val() + '&strategy=' + $('#strategy').val();   
            var salt = $('#hashsecret').val();   
            $('#hash').val( calcMD5(textPlain + salt) ); 
        }   
        function FormSubmit() {   
            window.open("http://localhost/Evolution/WebChat/WebChat.aspx", 'formresult', 'height=640, width=480, resizable=yes, location=no, scrollbars=no, menubar=no, toolbar=no, status=no'); 
            $('#HtmlForm').submit(); 
        }             
    </script>           |