Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Catalyst: Dev
RFC for non-plugin ways of doing this...
 

Index | Next | Previous | View Flat


jshirley at gmail

Oct 15, 2008, 4:40 PM


Views: 561
Permalink
RFC for non-plugin ways of doing this...

I try to adhere to best practices concerning GET and POST, as such, I
tend to do a lot of redirects after POSTs.

I wrote a simple plugin that gives me a ->message method that I can
stuff in status messages that follows (via flash) in case of a
redirect. If there is no redirect, the messages go to stash.

In my view, I could just iterate over both flash and stash to display
any status messages but that's not quite ideal either. In the case of
a serialized view that is entirely data-driven, I'd have to have
another step rather than just include the messages key in the stash.

I've thought of an ActionClass similar to DefaultEnd but that doesn't
get me the nice $c->message method. So, I could have a controller
base method but then I have the action class and a controller base
class, when the plugin (which does interact with the dispatch cycle to
inspect the response in case of redirect) seems reasonable.

Thoughts?

Thanks,
-J

_______________________________________________
Catalyst-dev mailing list
Catalyst-dev[at]lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst-dev

Subject User Time
RFC for non-plugin ways of doing this... jshirley at gmail Oct 15, 2008, 4:40 PM
    Re: RFC for non-plugin ways of doing this... apv at sedition Oct 15, 2008, 4:54 PM

  Index | Next | Previous | View Flat
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.