Forum Moderators: open
As a rule of thumb: client site scripting is for the client's benifit, server side is for yours.
The best way to go is to use both client and server side scripting. Even if it seems that client side is a more logical approach, never rely on client side verification of any data; it's very easy to bypass, if it works at all (which it may not).
As a rule of thumb: client site scripting is for the client's benifit, server side is for yours.
I quite like the way you said this, :) but let me ask you, would you not agree that performing some minor validations on the client side wouldn't be that bad? (ie. form validations with no sensible data whatsoever... etc)
d#Nimrod
If it is important for the data being submitted to conform to the validation though you should still recheck it on the server side. The user may have js turned off, or may be submitting the data in a different way from your form to try and crack your script.
The topic is almost the same, but not quite...
Thanks :)