Form Generation Library - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: Form Generation Library (/showthread.php?tid=16439) |
Form Generation Library - El Forum - 09-13-2009 [eluser]Sixteh[/eluser] Okay, my problem seems to be something wrong with my config/setup on my server. =/ The validation doesn't work at all on my server, but it works perfectly on wamp localhost. Form Generation Library - El Forum - 09-14-2009 [eluser]groyk[/eluser] Hi I am new to CI and Form generator I just have one simple question. One of my controllers contains multiply forms. In the form generator I need something like Code: $this->form->destroy(); Else when I call Code: $this->form->open('my_form') I still get the output from the first. In short I would like to do like this Code: <? Form Generation Library - El Forum - 09-15-2009 [eluser]macigniter[/eluser] [quote author="echoDreamz" date="1252837760"]@macigniter where am I setting the full path for the uploads?[/quote] You would supply it as an attribute like this: Code: $config = array( Please see details for the config values in the CI user guide. Form Generation Library - El Forum - 09-15-2009 [eluser]macigniter[/eluser] [quote author="groyk" date="1252946144"] One of my controllers contains multiply forms. In the form generator I need something like Code: $this->form->destroy(); Else when I call Code: $this->form->open('my_form') I still get the output from the first. [/quote] This will be available in the next version! I will hope to release it soon. If you need that function instantly, feel free to insert this code right after the Form() function: Code: function flush() You can then use: Code: $this->form->flush(); in between two forms in the same controller. Don't forget to clear out the $data['form'] and/or $data['errors'] variables. Form Generation Library - El Forum - 09-16-2009 [eluser]echoDreamz[/eluser] @macigniter - I have still not figured out how to solve the upload issue. Where do I set the upload path for your library? Form Generation Library - El Forum - 09-16-2009 [eluser]groyk[/eluser] Quote:This will be available in the next version! I will hope to release it soon. If you need that function instantly, feel free to insert this code right after the Form() function: Thank you for this fast update. Now the Libary outputs multiply forms quite simple. However I can't get validation to work :-S Here is how I generate my forms Code: foreach($users->result() as $u): Form Generation Library - El Forum - 09-16-2009 [eluser]groyk[/eluser] Hi macigniter I think I found a small bug in the libary I have attatched following attributs to a "submit" button Code: $del_att = array('onclick' => "confirm('Are yo sure you want to delete?')"); It works fine, except that if you press cancel the library still redirect to the success page! Form Generation Library - El Forum - 09-16-2009 [eluser]groyk[/eluser] Quote:Thank you for this fast update. Now the Libary outputs multiply forms quite simple. Don't know what I did wrong!! Now the validation is working! I must have done something wrong in my view. Form Generation Library - El Forum - 09-16-2009 [eluser]echoDreamz[/eluser] @groyk I am not 100% sure, but shouldnt you "return confirm();" Form Generation Library - El Forum - 09-16-2009 [eluser]groyk[/eluser] [quote author="echoDreamz" date="1253144867"]@groyk I am not 100% sure, but shouldnt you "return confirm();"[/quote] Hi echoDreamz Thank you, that did the trick! Stupid me, just copy pasted from another script! |