Wiki Cookbook

If you happen to write a good mailing list post, preserve it here as an article for immortality. People never seem to check the mailing list archives, so your work is usually wasted there :)

The end goal is to make something coherent, but for now, just dump your posts here.

Articles

Misc

"Next Page" Redirect - simple ?next_page=blah functionality like YouTube (when logging in to view a video)

Reusable Controllers - a method for reusing multiple controllers in an application

Search Example - a quick and dirty search example using Yahoo::Search

Return Your Schema Connection Information - return the value of your Catalyst::Model::DBIC::Schema's config's connect_info.

Configure Local Schema Connection Information - Set DBIC connect_info based on your local environment.

Safe Dispatch Using a Path - a safe way to invoke $c->forward(), $c->go() and friends given a path to an action

URL Path Prefixing - using global URL prefixes to handle e.g. languages ("/en/foo/bar", "/fr/foo/bar") or simulating multiple sites ("/site1/foo/bar", "/site2/foo/bar")

Front End Proxy - Configuring catalyst for use with a front end proxy such as Apache or nginx.

Passing Config to Your Schema - Keep your config at one place using SchemaProxy

Hashing Passwords - using DBIx::Class::EncodedColumn to keep your users' passwords secure.

Controller with File Upload - yet another CRUD Controller, with File Upload. Files are stored using DBIx::Class::InflateColumn::FS and delivered using the X-Sendfile header

Modifying Logged Warnings and Errors - Intercept and modify Perl warnings and errors. Useful to add contextual information to aid debugging and troubleshooting.

View

TT Pager

Testing Your Template - ensure that $c->stash->{template} is set correctly in a unit test

Setting the Default Template - One template file for all action methods in your controller

Reusing HTML Between Views - a method for using HTML generated in Catalyst::View::TT elsewhere.

My tags:
 
Popular tags:
  cookbook
Powered by Catalyst
Powered by MojoMojo Hosted by Shadowcat - Managed by Nordaaker