Displaying 1 result from an estimated 1 matches for "phonenumberformat".
2006 Oct 20
7
MVC and modules. Views telling models to behave
...odel for the duration of the views run.
It seemed to me that this would be more objecty than say a helper that
formats a string
format_my_string( my_string )
Instead, in my view. Lets assume I have a Building class that has a
phone_number field
At the top of my view then
<% Building.include PhoneNumberFormat %>
The PhoneNumberFormat module could overwrite the getter methods of
phone_number, fax_number etc to provide me with some nice formatting.
Presumably I could also pass some parameters somewhere (not quite sure yet)
so that I could tell the PhoneNumberFormat what kind of format I want.
Then my...