Which is better - client-side validation or server-side validation?
Server-side validation is required because client-side validation can be changed. However, client-side validation usually provides a better user interface, since it requires fewer messages. Therefore, I would recommend using both.
You MUST perform server side validation. Otherwise, anyone can send anything (think of a browser with JavaScript disabled or a custom fake browser).
, , .
:
.
ASP.NET , . , , , .
, .
AJAX.
, , , . , , DRY ( ) / (: ASP.NET ).
, , POSTS Ajax: , POST ( - ), JSON , - . , JSON, , , .
, , POST ( ASP.NET, ), .