Get and Set value into the input fields simultaneously.
HTML:
<input id="field1" onkeyup="get_set_value_for_field1()" type="text" />
<input id="field2" onkeyup="get_set_value_for_field2()" type="text" />
<input id="field2" onkeyup="get_set_value_for_field2()" type="text" />
SCRIPT:
function get_set_value_for_field1() {
document.getElementById('field2').value = document.getElementById('field1').value;
}
function get_set_value_for_field2() {
document.getElementById('field1').value = document.getElementById('field2').value;
}