Thanks,

I found it in the cookbook right after I sent the message but thanks for
your time!

Happy New Year.

Dave 

-----Original Message-----
From: cake-php@googlegroups.com [mailto:cake-...@googlegroups.com] On Behalf
Of Jeremy Burns
Sent: January-02-10 12:50 AM
To: CakePHP
Subject: Re: $this->Session->setFlash();

Hi Dave

Here's how you can do it:

$this->Session->setFlash(__('Your message.', true), true, array ('class' =>
'yourClass'));

On Jan 2, 2:35 am, "Dave" <make.cake.b...@gmail.com> wrote:
> I was wondering is there a way to add a class to the session from the 
> controller?
>
> The setflash as far as i can see is used for alerting user after a 
> save attempt so
>
> $this->Session->setFlash(__('Information Updated.', true));
>
> or
>
> $this->Session->setFlash(__('Error! Please try again.', true));
>
> So the idea would be for the success message add a class so the 
> message text is green if failed text is red.
>
> Any way this can be done?
>
> Dave

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+unsubscr...@googlegroups.com For more options, visit this group 
cake-php+at http://groups.google.com/group/cake-php?hl=en
No virus found in this incoming message.
Checked by AVG - www.avg.com
Version: 9.0.725 / Virus Database: 270.14.123/2595 - Release Date: 01/01/10
05:50:00

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+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to