[Catalyst] Capture page on server?

Kieren Diment diment at gmail.com
Mon Jun 23 13:05:43 BST 2008

On 23 Jun 2008, at 21:45, Martin Ellison wrote:

> Sorry, bit of a newbie question: is there any way that I can run an  
> action
> but capture the results (server-side) to a file? Doing so client  
> side is
> easy (eg wget) but I want to keep the page text on the server and to
> automate the page generation/save.

 From Catalyst::View::TT:

      render($c, $template, \%args)

Renders the given template and returns output, or a  
Template::Exception       object upon error.     ...


my $var = $c->render($template, \%args);
my $file = '/what/ever.html';
print $FH, ">", $file;

More information about the Catalyst mailing list