Eventos en jQuery

/*<form method="post"> Introduce código postal: <input type="text" id="codigo"/><br/> Introduce estado y ciudad: <input type="text" id="ciudad"/> <br/> </form><br/> <button id="btn10">Localizar en jQuery</button> */ $("button#btn10").on("click",()=>{ var codigo = $("input#codigo").val(); var ciudad = $("input#ciudad").val(); alert("Codigo: "+codigo+" , Ciudad: "+ciudad); });
Acceder a elementos de un form desde jQuery

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.