> But, apart from the "some users don't have Javascript turned 
> on" argument, why can't JS code be written that can validate 
> as well as CF?  ( I know I can't write the JS code right now, 
> but that's beside the point...)

A bunch of people have already answered this, so I don't know if I'll add
anything new here, but this is a fundamental issue in web application
development so you should be sure to understand it.

Web applications know absolutely nothing about anything that happens in the
browser. There is no guarantee that any JavaScript has run, or could run.
There is no guarantee that there even is a browser. You can, for example,
use any telnet client to send HTTP requests. The HTTP request contains a
bunch of request headers, from which your application might infer some
information about the client, but there is no guarantee that any of it is
correct. An HTTP request is just a big string of text, and could come from
any program that can send strings of text to specific TCP ports.

And, even if you could know there was a browser, and that the browser could
run JavaScript, you would have no guarantee that it would run it correctly.
You have no control over what happens in the browser, only what happens on
the server. On the server, you can guarantee that validation does what it's
supposed to do.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!

This email has been processed by SmoothZap - www.smoothwall.net


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Create Web Applications With ColdFusion MX7 & Flex 2. 
Build powerful, scalable RIAs. Free Trial
http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJS 

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:275230
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to