PHP Classes

What does this class do?

Recommend this page to a friend!

      PHP Forms Class with HTML Generator and JavaScript Validation  >  PHP Forms Class with HTML Generator and JavaScript Validation package blog  >  How to Show Google Ma...  >  All threads  >  What does this class do?  >  (Un) Subscribe thread alerts  
Subject:What does this class do?
Summary:What does this class do?
Messages:3
Author:Tim Martin
Date:2010-01-03 20:00:29
Update:2010-01-04 16:10:46
 

  1. What does this class do?   Reply   Report abuse  
Picture of Tim Martin Tim Martin - 2010-01-03 20:00:29
I was looking for code that would generate forms corresponding to tables in SQL databases.

And this class appeared in the "Top 10" list so I downloaded it.

But I cannot see a description of what it does.

Probably I have overlooked something. Could someone tell me what it does, or give me a reference to a description of what it does?

Thanks You

  2. Re: What does this class do?   Reply   Report abuse  
Picture of Manuel Lemos Manuel Lemos - 2010-01-03 20:51:01 - In reply to message 1 from Tim Martin
A detailed description of the class features is here:

phpclasses.org/browse/package/1.htm ...

But in case it is not clear, this class generates HTML forms from a definition of the list of the inputs that you want in the form.

It also determines if a form is being submitted and validate the form input values according to validation rules that you specify.

This is in few lines what the main class does. Then there are plug-ins to enhance the core functionality.

For managing data stored in databases, you probably want to take a look at the form scaffolding plug-in. It is a plug-in that makes possible to quickly generate CRUD user interfaces, i.e. user interfaces for creating, reading, updating and deleting information records stored in databases or any other kind of storage.

This plug-in is not specific to use with databases, but you can easily configure it to manage data that you have in your database tables.

You can start taking a look at the test_scaffolding_input.php example script. It demonstrates how to use this plug-in manage blog posts. The example stores the blog posts in session variables just for demonstration purposes. If you wanted to store the blog posts in a database, you just would need to change the class in blog_post_model.php script.

The presentation details may be configured in the class in blog_post_view.php script.

This separation of form processing, data storage and presentation forms what is known as the MVC architecture.

The code is commented everywhere so you can easily learn how to adapt the examples to you applications.

You may also want to read more about this plug-in here:

phpclasses.org/blog/package/1/post/ ...

Here is a live example:

meta-language.net/forms-examples.ht ...

Just let me know if you have further questions.

  3. Re: What does this class do?   Reply   Report abuse  
Picture of Tim Martin Tim Martin - 2010-01-04 16:10:46 - In reply to message 2 from Manuel Lemos
Thank you for that.

I am now working my way through some examples.