Page 1 of 1

FORM generators

Posted: Fri Aug 11, 2006 5:43 pm
by alex.barylski
Which ones exist?

The only one I know of is HTML_QuickForm...

I'm looking into using one on my current project, see what happens... :P

Anyways, I'd like to hear the pros and cons of any you know of, even that mentioned above...???

Cheers :)

Posted: Fri Aug 11, 2006 5:48 pm
by Luke
I love the one you mentioned. Works great. You can completely customize the output (comes with support for a number of template systems, as well as the ability to write your own renderer plugin)... write plugins for extra rules/filtering. It's great. Form validation is so easy now that I use it.

Posted: Fri Aug 11, 2006 10:06 pm
by neophyte
Fill me in who made it? Where can you find it? Is it oop or proceedural etc....

Posted: Sat Aug 12, 2006 12:54 am
by matthijs
Maybe have a look at Manuel Lamos' class Forms generation and validation at phpclasses. Haven't used it myself but have been keeping an eye on it. Looks very complete and is in very active development. Is at ranking no 1 on phpclasses so it's certainly not the worst class there.

Another one which I do have experience with is http://www.formhandler.net/. Works very well and is quite complete too. It's a class which let you generate forms easily and do stuff with the results (show error messages, email data or sent th data to db, etc). However, as it is a standalone complete class, I'm not sure how easy it will be if you have special needs or want to integrate it (functionally) in an existing framework of code. You'll have to take a look at the code for that.

Sorry I can't give you more details, but maybe these 2 are interesting enough to have a look at.

Posted: Sat Aug 12, 2006 1:07 pm
by alex.barylski
That Manuel guy has quite a bit of code on phpclasses...seems to be a well respected guy...

Although I think I'm gonna take a stab at CSS forms, see how it goes...in which case I need to likely hand code them :)

I'll look into that second class for sure, never heard of that one :)

Cheers :)

Posted: Sat Aug 12, 2006 1:46 pm
by matthijs
Yes I guess that's a drawback of many existing solutions: it's hard to control the exact output. In other words, you'll get a bunch of tables, no css, no clean markup etc. (if you find one, please let me/us know)

Posted: Sat Aug 12, 2006 1:57 pm
by alex.barylski
I can't be bothered to even look, as I'm not a huge fan of FORM generators, but I've suggested to Oren he considered looking into writting a CSS generator...

So hopefully he has something in the works :)

Posted: Sat Aug 12, 2006 3:36 pm
by Luke
like I said... HTML_QuickForm lets you customize the output. I haven't done it yet, because so far it's been very easy to just style the generated forms (but I haven't used it for any real complicated forms yet). It allows you to write your own renderer and has built-in support for smarty and a couple other template engines. I was considering writing my own until I found this one. Very easy and fast.

Also, for those of you who aren't aware, this is a Pear package.