added text field validation