Hello everyone,

I'm upgrading my simple CMS app, and would like to add a [simple] function to it—which I'm finding is no so simple (at least for me). To illustrate:

The user clicks "Edit" on a particular table row. The CMS then fetches that row from the table and begins displaying the value of each field in a form (which the user can then edit and at then click "Update") . So far, so good.

What I want to add is a function that will, depending on the field type (text, set, enum), display the field value as either a <textarea> or <select><option>. For example, for a field called "status", which is of type ENUM, and can contain the values "Online" or "Offline", I want this CMS function to return something like "<select><option>..." along with the allowed values, with the active one selected.

Beyond this, I'd like to extend this check_field_type function to handle fields that contain links to images, etc. But this is where I need to start.

Thanks.

...Rene

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to