Form Generation Library |
[eluser]Maglok[/eluser]
Greetings people of the awesome form gen lib thread. I have a question. There is a clear() function to define two forms. Awesome. Is there a way to detect which one gets submitted without the errors entangling? I got a wip webapp here: http://pona.dev.fss.uu.nl/ It allows you to login or to register on the same page. I have this as form generation code: Code: // Build new user form That works. But it is the handling of said forms. I have tried messing with it a bit, but I can't seem to get the errors to not highlight everything when the input is wrong, nor is this very neat. The docs aren't complete on the valid function. I basically need to be able to validate each form seperately instead of $this->form->valid. Code: // Decide what form is being submitted [code]
[eluser]Mantra of Doom[/eluser]
Hi everyone, I have a two page form on my site. The first page of the form is the same for everyone and posts to one table called Characters. The second page of the form changes depending on a drop down selection on the first page. Right now, I have the second page split up into different controllers depending on which option is selected, but I'm not sure how to send the user to the correct controller once the first form is submitted. The data in the second page of the form is also save to a different table, again, depending on that one selection. Can I call an if statement in the onsuccess method? What would be the best practice for this sort of thing? There are 30 options in the list to choose from and there could be more depending on the growth of the site.
[eluser]pabloheim[/eluser]
Hi ! anyone has tested this library on codeigniter 2?
[eluser]Basketcasesoftware[/eluser]
I'm about to try it. It is using PHP 5.0, so there shouldn't be a compatibility problem that way anyways.
[eluser]joytopia[/eluser]
[quote author="pabloheim" date="1297218284"]Hi ! anyone has tested this library on codeigniter 2?[/quote] Yes, I am using it on codeigniter 2. No problems. Best regards Bernd
[eluser]pabloheim[/eluser]
[quote author="joytopia" date="1297249798"][quote author="pabloheim" date="1297218284"]Hi ! anyone has tested this library on codeigniter 2?[/quote] Yes, I am using it on codeigniter 2. No problems. Best regards Bernd[/quote] Great!. im going to test it right now!
[eluser]sahanlak[/eluser]
Just got an error, Code: Message: Object of class El could not be converted to string Quote:->text('method', 'Payment Method', '', $user->method) Error was gone after this Code: ->text('payment_method', 'Payment Method', '', $user->method)
[eluser]sahanlak[/eluser]
Code: ->select('payment_method', $methods, 'Payment Method', $user->method) Generates Code: <select name="payment_method[]" id="payment_method"> why its adding the [] ?
[eluser]Mat-Moo[/eluser]
http://www.frankmichel.com/formgenlib/us...elect.html Quote "Note: This method will return the selected values as an array." That's why...
[eluser]sahanlak[/eluser]
[quote author="Mat-Moo" date="1297444418"]http://www.frankmichel.com/formgenlib/user_guide/elements/select.html Quote "Note: This method will return the selected values as an array." That's why...[/quote] Oh ok, I didn't think so since its a single select drop down. Thanks |
Welcome Guest, Not a member yet? Register Sign In |