Hi All,

I have searched and I can't find an answer anywhere so I ask the
question...

I would like to display and use derived values in a view....

The model knows how to calculate these values form it's own data.. but
how do I call these methods in a view..

For example I have a model called event I have defined 2 methods
canRegister and regsiterDate

Can register returns true if a user can register for the event and
registerDate returns the date that registrations open...

I would like the list (index.thtml) to display the regiser date if you
can't register and a link if you can...

however I can't see to call these methods from the view??

I tried echo $event['event']->registerDate()  but it didn't work...
I don't want to store the register date in the database as in the
event of a rule change I want to update the model and not have to
patch all the data for existing events.
any help would be greatly appreciated.

Craig.


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to