Re: Flash Session Variable

2011-06-15 Thread MrSensitive
Or instead of reinventing the wheel just using it the way it is
supposed to be used in the first place?

http://www.jamesfairhurst.co.uk/posts/view/custom_cakephp_flash_messages_updated/




On 15 jun, 09:38, Jeremy Burns | Class Outfit
 wrote:
> You can do something like this:
>
> if ($this->Session->check('Message.flash')):
>         $message = this->Session->read('Message.flash')
>         $this->Session->delete('Message.flash');
> endif;
>
> ...and then process $message as you like. A bit long winded, but...
>
> Jeremy Burns
> Class Outfit
>
> jeremybu...@classoutfit.comhttp://www.classoutfit.com
>
> On 15 Jun 2011, at 00:47, Ryan Schmidt wrote:
>
> > How about
>
> >  > $flash = $this->Session->flash();
> > if (!empty($flash)) {
> >    echo '' . $flash . '';
> > }
> > ?>
>
> > On Jun 14, 2011, at 17:00, Krissy Masters wrote:
>
> >> Missed the part where i said "I know about the flash session class options
> >> but I need something more than a class in this case." Its more than just a
> >> class div I need.
>
> >> -----Original Message-
> >> From: cake-php@googlegroups.com [mailto:cake-php@googlegroups.com] On 
> >> Behalf
> >> Of Ryan Schmidt
> >> Sent: Tuesday, June 14, 2011 7:12 PM
> >> To: cake-php@googlegroups.com
> >> Subject: Re: Flash Session Variable
>
> >> On Jun 14, 2011, at 15:06, Krissy Masters wrote:
>
> >>> I know about the standard Session->flash(); ?>
>
> > --
> > Our newest site for the community: CakePHP Video 
> > Tutorialshttp://tv.cakephp.org
> > Check out the new CakePHP Questions sitehttp://ask.cakephp.organd help 
> > others with their CakePHP related questions.
>
> > To unsubscribe from this group, send email to
> > cake-php+unsubscr...@googlegroups.com For more options, visit this group 
> > athttp://groups.google.com/group/cake-php

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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


Re: Flash Session Variable

2011-06-15 Thread Jeremy Burns | Class Outfit
You can do something like this:

if ($this->Session->check('Message.flash')):
$message = this->Session->read('Message.flash')
$this->Session->delete('Message.flash');
endif;

...and then process $message as you like. A bit long winded, but...

Jeremy Burns
Class Outfit

jeremybu...@classoutfit.com
http://www.classoutfit.com

On 15 Jun 2011, at 00:47, Ryan Schmidt wrote:

> How about
> 
>  $flash = $this->Session->flash();
> if (!empty($flash)) {
>   echo '' . $flash . '';
> }
> ?>
> 
> On Jun 14, 2011, at 17:00, Krissy Masters wrote:
> 
>> Missed the part where i said "I know about the flash session class options
>> but I need something more than a class in this case." Its more than just a
>> class div I need.
>> 
>> -Original Message-
>> From: cake-php@googlegroups.com [mailto:cake-php@googlegroups.com] On Behalf
>> Of Ryan Schmidt
>> Sent: Tuesday, June 14, 2011 7:12 PM
>> To: cake-php@googlegroups.com
>> Subject: Re: Flash Session Variable
>> 
>> 
>> On Jun 14, 2011, at 15:06, Krissy Masters wrote:
>> 
>>> I know about the standard Session->flash(); ?>
> 
> -- 
> Our newest site for the community: CakePHP Video Tutorials 
> http://tv.cakephp.org 
> Check out the new CakePHP Questions site http://ask.cakephp.org and help 
> others with their CakePHP related questions.
> 
> 
> 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

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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


Re: Flash Session Variable

2011-06-14 Thread Ryan Schmidt
How about

Session->flash();
if (!empty($flash)) {
echo '' . $flash . '';
}
?>

On Jun 14, 2011, at 17:00, Krissy Masters wrote:

> Missed the part where i said "I know about the flash session class options
> but I need something more than a class in this case." Its more than just a
> class div I need.
> 
> -Original Message-
> From: cake-php@googlegroups.com [mailto:cake-php@googlegroups.com] On Behalf
> Of Ryan Schmidt
> Sent: Tuesday, June 14, 2011 7:12 PM
> To: cake-php@googlegroups.com
> Subject: Re: Flash Session Variable
> 
> 
> On Jun 14, 2011, at 15:06, Krissy Masters wrote:
> 
>> I know about the standard Session->flash(); ?>

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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


RE: Flash Session Variable

2011-06-14 Thread Krissy Masters
Missed the part where i said "I know about the flash session class options
but I need something more than a class in this case." Its more than just a
class div I need.

-Original Message-
From: cake-php@googlegroups.com [mailto:cake-php@googlegroups.com] On Behalf
Of Ryan Schmidt
Sent: Tuesday, June 14, 2011 7:12 PM
To: cake-php@googlegroups.com
Subject: Re: Flash Session Variable


On Jun 14, 2011, at 15:06, Krissy Masters wrote:

> I know about the standard Session->flash(); ?>
> 
> 
> 
> But I want to wrap it inside a div with an isset() so the div will only
> appear with the presence of an actual message but what is the variable to
> check for? Is there a way to grab the actual message variable and isset( $
> message variable ) but if so what is that?
> 
> I know about the flash session class options but I need something more
than
> a class in this case.

Doesn't it already come in a div?


-- 
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help
others with their CakePHP related questions.


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

-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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


Re: Flash Session Variable

2011-06-14 Thread Ryan Schmidt

On Jun 14, 2011, at 15:06, Krissy Masters wrote:

> I know about the standard Session->flash(); ?>
> 
> 
> 
> But I want to wrap it inside a div with an isset() so the div will only
> appear with the presence of an actual message but what is the variable to
> check for? Is there a way to grab the actual message variable and isset( $
> message variable ) but if so what is that?
> 
> I know about the flash session class options but I need something more than
> a class in this case.

Doesn't it already come in a div?


-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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