I'm needing that when I put any value inside input1, that value already appears in input2. Since both are on the same page, can you do that?
I'm needing that when I put any value inside input1, that value already appears in input2. Since both are on the same page, can you do that?
You can do with jQuery by capturing the keyup
event.
Run the code below and see below an example working:
// JavaScript (usando jQuery).
$('#input1').keyup(function(){
$('#input2').val($(this).val());
});
<!-- HTML -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script><inputid="input1"/>
<input id="input2"/>