The page includes two forms: easyform and hardform. The checkName() function validates the name field of easyform, not hardform!