Si tengo varios input que con el onkeyup pasa automaticamente a otro ¿cómo hago para que al borrar regresa automaticamente al input anterior?
Aquí un ejemplo varios input que con el onkeyup pasa automaticamente a otro ¿cómo hago para que al borrar regresa automaticamente al input anterior?
<input type="text" name="da" maxlength="1" max="9" min="0" required
onkeyup="if (this.value.length == this.getAttribute('maxlength')) input2.focus()" autocomplete="off">
<input type="text" id="input2" name="db" maxlength="1" max="9" min="0" required
onkeyup="if (this.value.length == this.getAttribute('maxlength')) input3.focus()" autocomplete="off">
<input type="text" id="input3" name="dc" maxlength="1" max="9" min="0" required
onkeyup="if (this.value.length == this.getAttribute('maxlength')) input4.focus()" autocomplete="off">