validating input to text fields before enabling post