Just out of curiousity, why doesn't this work??
if (fname == "")
Your solution seems to only check if the value has characters specified in your code in it; not if the value is empty.
if( !/[a-z]{2}/i.test( fname ) )
{
alert("Please enter your first name.");
return false;
}
I am not knocking your code (it is beautiful), but I am merely confused why you cannot ask if a variable's value is empty.