Validate ID in a form