jtrovato
11-07-2002, 10:28 AM
I have a client who is lazy! Don't we all
well anyway, he wants to know if I could code my php to auto jump (tab) to the next field when it hits the end.
ie.
(516) 555 - 1212 - each one of these are in a different input field.
this is the function I use to capture then phone number
function GetPhone ($Var,$extVar)
{
echo "(<input type=text name=".$Var."1 size=3 maxlength=3>)";
echo "<input type=text name=".$Var."2 size=3 maxlength=3>-";
echo "<input type=text name=".$Var."3 size=4 maxlength=4>";
if ($extVar!="")
echo " Ext <input type=text name=".$extVar." size=5 maxlength=5>";
}
I would like to know if there is a way to have it move over to the next input field using java script so the user can just keep typing away.
Thanks for the input..
John
well anyway, he wants to know if I could code my php to auto jump (tab) to the next field when it hits the end.
ie.
(516) 555 - 1212 - each one of these are in a different input field.
this is the function I use to capture then phone number
function GetPhone ($Var,$extVar)
{
echo "(<input type=text name=".$Var."1 size=3 maxlength=3>)";
echo "<input type=text name=".$Var."2 size=3 maxlength=3>-";
echo "<input type=text name=".$Var."3 size=4 maxlength=4>";
if ($extVar!="")
echo " Ext <input type=text name=".$extVar." size=5 maxlength=5>";
}
I would like to know if there is a way to have it move over to the next input field using java script so the user can just keep typing away.
Thanks for the input..
John
