Re: Idea for a new Package - Chained Selectors

From: Date: Sun, 19 Sep 2004 04:11:37 +0000
Subject: Re: Idea for a new Package - Chained Selectors
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-33444@lists.php.net to get a copy of this message
     
But some of us quake in fear at using Quickform :)
       
I see no reason why one would quake in fear at using QuickForm. Unless you really enjoy writing repetitive HTML and validation code. FYI, QuickForm is being used today in very complex web sites with very complex registration, orders, carts processes. And it runs very well while still making it easy to maintain/change the forms and logic to fit customers needs, that are prone to change more often than one thinks. I better clarify that comment a little: QuickForms is a great, well supported and mature package, I can see alot of people using without any problem. and it does solve that rapid form prototyping issue very well. This is where the big 'however' comes in. I did spend (what must of been 2-3 months trying to integrate it as a backend to Flexy), and in the end came to the conclusion it was not technically feasible, and that having become familar with the design of QF, I would be very unlikely to consider ever using it. Why? - It mixes control (eg. it reads / writes $_GET/$_SET/$_SESSION), with rendering, validation and data storage. (This is my biggest dislike of the package, and I've made the same mistake in my code and regretted it ever since. It causes considerable unpredictability to occur, when working outside the standard operating procedures) - The requirement of having to deal with &alias'es everywhere makes it a minefield of potential mistakes. - It's not quick and simple to debug, print_r() on the main object results in an excess of information. - The heavy use (an perhaps needless) of privates makes it almost impossible to extend for other purposes. - The migration path for QF to custom layout forms (that could be visually designed by a wysiwyg editor) is messy to put it midly, (almost all the form designs I do end up being visually layed out now - athough alot are in XUL these days.) All that said, these are what my experience/opinion of the code is, and I dont expect to find agreement in those points.... but I was asked why.... So what do I use instead: HTML - layout Flexy's Element as a representation of the form elements Flexy's Element Factory has some ability to assign bulk data to a form, but I rarely automate that too much.. javascript libraries / Validate / Gtk_validate_manager for validation. While I can't say one solution is better than the other, And there are parts that I dislike about my own solution. QF unfortunatly for me caused more problems than it solved. Regards Alan


« previous php.pear.dev (#33444) next »