Client Side Validation for 2.3

UI Components for JSF
Post Reply
cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

02 Nov 2010, 19:35

Dear PrimeFaces Community,

I'm wondering if you'd like to see Client Side Validation in 2.3, in the past I've done a proof of concept work on myfaces tomahawk;

http://example.irian.at/example-sandbox ... rdForm.jsf

Personally I'd like to see something similar and much better in PrimeFaces.

Thanks for your feedback,

Cagatay Civici
PrimeFaces Lead

User avatar
bardu
Posts: 293
Joined: 30 Dec 2009, 08:27
Location: Canada

02 Nov 2010, 20:01

Personally, I would prefer to see PF mobile and Ajax push coming out as soon as possible.

Client side validation can wait until 2.4.
JSF-2.0, mojarra-2.1 | PrimeFaces-3.0-M1 | GFv3.1 | NetBeans 7 | Ubuntu 11.04
www.yukonlive.ca
www.yukonlive.de

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

02 Nov 2010, 20:32

Yes, this is something after, highlights of 2.3 is Ajax Push and PrimeFaces Mobile.

User avatar
bumble.bee
Posts: 723
Joined: 29 Sep 2010, 21:39
Location: United States

02 Nov 2010, 21:37

Client side validation is definately a nice to have. It is an optimization though (reduce server load and speed up user experience).

My vote is to spend extra time making PrimeFaces more stable (and usable). Make sure existing components work well with each other and can be combined in dialogs and such. Also, add features to existing components such as adding subTables to dataTables.

User avatar
MISS_DUKE
Posts: 273
Joined: 08 Aug 2010, 05:52

03 Nov 2010, 03:01

Client side validation is not so important as we can do server side validation using Ajax which more or less resembles (in the point of the user) client side validation.
JSF implementation: Mojarra V2.1.7
JSF component library: Primefaces V3.1.1
Server: GlassFish Open Source Edition V3.1.1 (build 12)

User avatar
Oleg
Expert Member
Posts: 3805
Joined: 02 Oct 2009, 09:41
Location: Germany, Black Forest

03 Nov 2010, 13:18

Hi,

I didn't have a good experience with client-side validation because it doesn't help in most cases. If you use user-specific date / time formats, time zones or something like you need to do a request in order to proper server-side validation. What can you validate client-side? For requiered fields we don't need a client-side validation framework. For masked input we have p:inputMask or can even archieve that with a simple JS reg. expression. Could you say me an example where such validation framework is really needed?

Thanks.
PrimeFaces Cookbook (2. edition): http://ova2.github.io/primefaces-cookbook/ Learning Angular UI Development with PrimeNG: https://github.com/ova2/angular-develop ... th-primeng Blog: https://medium.com/@OlegVaraksin

healeyb
Posts: 365
Joined: 07 Apr 2010, 16:05

03 Nov 2010, 13:57

I'd agree with comments already expressed that client-side validation is
more of an optimisation than anything else, but, and it's a big but, I've
yet to be in a position to see just what the impact of all this ajax is on
a heavily loaded production server. I'd still tend to assume that validation
would only account for a comparitively small proportion of the ajax
overhead though.

Mobile apps are firmly at the top of my list also, and who doesn't rate
stability as a topmost priority.

Regards,
Brendan.

User avatar
Oleg
Expert Member
Posts: 3805
Joined: 02 Oct 2009, 09:41
Location: Germany, Black Forest

03 Nov 2010, 16:13

One reason more against client-side validation: How do you plan to internationalize messages? For multi-language web apps you should keep all validation messages for all languages on the client-side (we want to avoid roundtrips to server). Right? It's acceptable for you to have 300-400 long text in JavaScript object(s)? How do you plan to maintain this stuff? Java property files, in contrast, can be easy sent to an interpreter.

Client-side validation is normally not enough and we should repeat all validation steps on the server-side. One of rules in the web development says - not trust client-side, backend should always do validation as well if the front-end UI technology will be changed in the future or the same backend is used by another clients. Right? That means, messages and all validation related implementations are repeated twice, client-side and server-side. You maybe save an ajax call, but wast time with coding. It's really acceptable for you?
PrimeFaces Cookbook (2. edition): http://ova2.github.io/primefaces-cookbook/ Learning Angular UI Development with PrimeNG: https://github.com/ova2/angular-develop ... th-primeng Blog: https://medium.com/@OlegVaraksin

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

03 Nov 2010, 18:42

Thanks for all the feedback, was really helpful. I think we have more to do(e.g. Ajax Push, PrimeFaces Mobile, portlet samples, new components, bug fixes) before thinking about client side validation.

callahan
Posts: 768
Joined: 27 May 2010, 22:52

03 Nov 2010, 21:57

I missed the party here, but I like the outcome.

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 29 guests