Skip to content

Instantly share code, notes, and snippets.



Created Mar 14, 2014
What would you like to do?
<form method="post" class="formulario-early-suscriber" id="form-plan-anual">
<input name="email" placeholder="Escribe tu Email" type="email" required>
<input name="plan" value="anual" type="hidden">
<input name="precio" value="195 eur" type="hidden">
<button class="submit-form" data-em="button" type="submit">Avísame Cuando esté Listo</button>
<!-- Javascript Code -->
<script type="text/javascript">
$(document).ready(function() {
function enviar_email(ev){
var url = "early_suscribe.php";
var form = this;
type: "POST",
url: url,
data: $(form).serialize(), // Adjuntar los campos del formulario enviado.
success: function(data){
parent = $(form).parent();
parent.append('<p class="alert alert-success early-suscribe-success">'+data+'</p>');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment