Added post validation and error messaging