Server side validation in ashx or controller in MVC 2

Last post 09-26-2010, 9:09 PM by cutechat. 1 replies.
Sort Posts: Previous Next
  •  09-19-2010, 4:30 PM 64084

    Server side validation in ashx or controller in MVC 2

    In the sample there are comments that tell me to run server side validation in the ashx and the controller action, what is recommended?
    Paul
    Post Hope
  •  09-26-2010, 9:09 PM 64197 in reply to 64084

    Re: Server side validation in ashx or controller in MVC 2

    Hi,
     
    In ashx , you can throw an exception , the browser javascript will show alert for that message.
     
    If you validate the file in controller action , you can do more logic for the UI.
     
    Regards,
    Terry
View as RSS news feed in XML