blueman378 Posted December 2, 2008 Share Posted December 2, 2008 Hi guys, i was wondering whats the best way to generate a form and validate it dynamically i was thinking of a database table with Name Type Length Value(Nullable) fill this in and have predefined types, such as email, alphanumeric, numeric, alpha, timestamp, date, text, create the form, when it is submitted run it through a validator which reads the input type and validates off that anyone see a better way?> Link to comment https://forums.phpfreaks.com/topic/135128-generating-and-validating-a-form-dynamically/ Share on other sites More sharing options...
blueman378 Posted December 2, 2008 Author Share Posted December 2, 2008 *bump* Link to comment https://forums.phpfreaks.com/topic/135128-generating-and-validating-a-form-dynamically/#findComment-704474 Share on other sites More sharing options...
chronister Posted December 3, 2008 Share Posted December 3, 2008 I am actually working on a form class to do just this. It is in the VERY early stages of it and does not do much of anything useful yet, but my idea for this kind of thing is call member functions to create the form and assign values to stuff. I am then going to maybe have an array to keep track of the required fields. I am trying to figure out how to allow for complex forms and complex validation. Take a look at http://www.phpformclass.com/phpform/validation/1,2 It is a form class. The free one has no database integration though, the paid one is a hundred bucks. So I am basically going to write one of my own. Link to comment https://forums.phpfreaks.com/topic/135128-generating-and-validating-a-form-dynamically/#findComment-704523 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.