开发者

quick validation method

i have a form with 20 fields .. i have 2 options ...one to validate on client side and another on click of submit button do a validation from server side using ajax and show result.....

which开发者_运维问答 1 to choose...which is faster server side or client side.. i am developing a application ..its not a website.


i would do both.

client side should be easy with jquery validation plugin if the form is nothing out of the ordinary.

server side if you use any framework at work, it could be quick. if not it's just a lot of typing.


Always do server-side, regardless of speed. Client side is optional and will be faster, but can be disabled by disabling Javascript, and you do not want to implicitly trust user input.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜