I haven't tried this, but since it is a forward, can you set a request
attribute that can be accessed by the 404 action?

On Sep 14, 5:49 am, "rooster (Russ)" <[email protected]> wrote:
> Well, since the request is forwarded and not redirected it is possible
> to set any number of different variables that can be retrieved later,
> even something like sfConfig::set("404_message", "something"); would
> be sufficient.
>
> The problem is that you'd have to do that prior to calling 404
> function, so would be a pain with things like forward404Unless()
>
> It would be much nicer if the message passed as a parameter to the
> forward404 functions was available in the action that is handling the
> error - actually it would be best if the exception object itself was
> available. I'm actually surprised it isn't already, which why I wonder
> if I've overlooked something...
>
> Russ.
>
> On Sep 14, 11:34 am, Lee Bolding <[email protected]> wrote:
>
>
>
> > On 13 Sep 2009, at 18:12, rooster (Russ) wrote:
>
> > > In the meantime, unless anyone else can think of something, the only
> > > thing I can suggest is that you override the sf404Exception class to
> > > store the message for you.
>
> > I haven't tried this before, but you could try using my  
> > sfRequestPlugin (http://www.symfony-project.org/plugins/
> > sfRequestPlugin), setting the error using $request->setError(), then  
> > retrieve the error within your 404 module/action/template.
>
> > I haven't tested the plugin on SF 1.2 yet...

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"symfony users" 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/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to