[cvs] [Wiki] changed: NewFieldType

Wiki Guest wiki at wiki.horde.org
Sun Aug 21 20:06:25 PDT 2005


guest [65.19.150.231]  Sun, 21 Aug 2005 20:06:25 -0700

Modified page: http://wiki.horde.org/NewFieldType
New Revision:  7.0
Change log:  Revert

@@ -75,10 +75,10 @@
 I think the field class that returns the HTML edit representation needs to have a method for "gathering" the form fields back into the internal representation.  An example could be Horde's monthdayyear field, which has three form fields for representing a date value.  The gather() method would take this data and return the internal value. -- JasonFelice
 
 +++ Careful Attention to Internal Value Representations
 
-We've had this problem with our old framework, and I see it to some degree in Horde.  What does a date look like?  If we could pick one form, we constrain the number of interfaces we deal with and therefore the complexity.  In our old framework, we have internal (PHP) values, database (!PostgreSQL textual representation) values and HTML form values.  We assumed when first designing when we were basically just using text inputs that all of these were the same, but that got us into big touble.
+We've had this problem with our old framework, and I see it to some degree in Horde.  What does a date look like?  If we could pick one form, we constrain the number of interfaces we deal with and therefore the complexity.  In our old framework, we have internal (PHP) values, database (PostgreSQL textual representation) values and HTML form values.  We assumed when first designing when we were basically just using text inputs that all of these were the same, but that got us into big touble.
 
 In Horde, we can make sure the storage driver returns the internal form, so we seal off the database representation into the database-specific driver, which is really nice.  We currently do have a problem with the other types of values, though.  We should probably always use PEAR Date:: representations because we certainly don't want different fields for UNIX timestamp and more useful date formats.
 
 -- JasonFelice
 


More information about the cvs mailing list