Wednesday, March 31, 2010

Custom flash messages

I've been playing around trying to customize my flash messages with CSS and I'm having a bit of trouble. 

I tried to define the class with the message itself  .... 

[code]    $this->Session->setFlash(__(' Some Flash message here ', array('class' => 'flash_failure')));    [/code]

I also tried to use the example in the CookBook and create separate .ctp files in the layouts folder and defining the views that way but that didn't seem to work either. 

The message shows up fine in the view but it shows as plain text and no CSS style. 

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.
 
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

No comments: