Explorar o código

Contacto+newsletter

david %!s(int64=12) %!d(string=hai) anos
pai
achega
f5106fecfc
Modificáronse 1 ficheiros con 18 adicións e 3 borrados
  1. 18 3
      index.php

+ 18 - 3
index.php

@@ -30,7 +30,7 @@ header('Content-Type: text/html; charset=UTF-8');
             });
 
 	        $('li a').click(function () {
-	            $('html, body').animate({ scrollTop: $($(this).attr('href')).position().top }, 'slow');
+                $('html, body').animate({ scrollTop: $($(this).attr('href')).position().top }, 'slow');
 	            return false;
 	        });
 
@@ -50,6 +50,17 @@ header('Content-Type: text/html; charset=UTF-8');
                     $('#logo').css({'opacity':'0', 'transition': 'opacity 0.5s ease-in-out'});
                 }
             });
+            $("#btnconsulta").click(function() {
+                $.post('contacto.php',{nombre: $("#name").val(), mail:$("#email").val(),consulta:$("#message").val()}).done(function(data) {
+                    $("#respuestacontacto").html(data);
+                });
+            });
+            $("#ok").click(function() {
+                $.post('newsletter.php',{mail:$("#suscribe").val()}).done(function(data) {
+                    $("#respuestanewsletter").html(data);
+                });
+            });
+
 
             
         });
@@ -69,7 +80,9 @@ header('Content-Type: text/html; charset=UTF-8');
     <div id="exit"><h5>X</h5></div>
     <form action="" method="post" class="STYLE-NAME">
     <h5>Contacto</h5><br>
-    Un equipo de profesionales está a su servicio para responder sus consultas
+    Un equipo de profesionales está a su servicio para responder sus consultas<br>
+    Av. Bernardino Rivadavia 5427 3F, CABA (1424), Buenos Aires, Argentina.<br>
+    Tel&eacute;fono: +5411 4139-6860/1 +5411 4904-0289.
     <br><br>
     <label>
 
@@ -89,8 +102,9 @@ header('Content-Type: text/html; charset=UTF-8');
     <br> 
     <label>
         <span>&nbsp;</span> 
-        <input type="button" class="button" value="Send" /> 
+        <input id="btnconsulta" type="button" class="button" value="Enviar" /> 
     </label>    
+    <div id="respuestacontacto"></div>
     </form>
 </div>
 
@@ -308,6 +322,7 @@ OBJETIVOS DEL CURSO: Obtener los conocimientos teóricos y prácticos en el áre
             <div id="input-footer">
                 <input id="suscribe" type="text" /> 
                 <input id="ok" type="submit" value="Inscribirse" />
+                <div id="respuestanewsletter"></div>
             </div>
 
         </div>