| Let's Talk About Fields |
| Content Type Management | |||
| Written by Ercan Özkaya | |||
|
My project is mostly about different kinds of fields that will keep data for content types. So I think mentioning them a bit is not a bad idea. Fields are the things that will generate HTML code for forms and they will also deal with the columns in database that will hold the actual data. They are very much like Joomla! plugins. This makes adding and even developing fields easier. They consist of two files:
For each field instance, a row in database is created to store parameters and column data. These parameters make each instance configurable. For example, if the field is required to be filled in forms, there will be a parameter for that in params column. Next thing to mention is PHP classes for fields. They will be similar to JElement derivatives in Joomla! framework. A renderer method will take the database row and output an HTML field for forms. For example, a simple text field renderer will output something like that: <input name="text_field" id="text_field" class="inputbox required" value="Value coming from database" /> They may be installed using normal Extension Manager of Joomla! in the future (hopefully in 1.6). But for now, I'll have a seperate installer in my component for installing/uninstalling fields. First thing in my mind before designing this system was to make fields pluggable to allow third party field types. I think this system will give developers some flexibility to create new field types. But if you think something is wrong with this system and have suggestions, I'm eager to hear them.
|




Sat 05 Jul 2008 19:52:35 EDT
Mon 07 Jul 2008 08:56:38 EDT
Fri 25 Jul 2008 17:49:26 EDT