Basic registration code added including simple javascript validation