Questions tagged [catalyst]

Catalyst is a Perl web application framework, similar to Ruby on Rails, Spring (Java), and Maypole.

Catalyst is an elegant web application framework written in the Perl programming language, extremely flexible yet extremely simple. It's similar to Ruby on Rails, Spring (Java), and Maypole, upon which it was originally based. Its most important design philosphy is to provide easy access to all the tools you need to develop web applications, with few restrictions on how you need to use these tools.

http://www.catalystframework.org/

Resources to learn Catalyst:

Useful Links:

524 questions
6
votes
5 answers

Is it feasible to learn Perl and Catalyst at the same time?

Is it feasible to learn Perl and Catalyst at the same time? If so, what would be the typical path? I am experienced .Net/C#/C++ developer but fairly new to Perl
Krishnan
6
votes
2 answers

What's the easiest way to test a Catalyst REST API

I'm building a RESTful web service, using Catalyst::Controller::REST. Usually for web testing I use Test::WWW::Mechanize, but that seems more appropriate for "GET/POST HTML RPC" testing. Are there any Test modules that would make testing of HTTP…
xenoterracide
  • 16,274
  • 24
  • 118
  • 243
6
votes
5 answers

Template-Toolkit and complex variables

Say I'm working in Perl using Catalyst. I assign an array of hashes to a a variable, ie: my @array = ($some_hash); $c->stash->{foo}->{bar} = \@array; How do I select an element from $some_hash, such as 'id', in Template Toolkit? In Perl I can…
danwoods
  • 4,889
  • 11
  • 62
  • 90
6
votes
2 answers

How do I prevent DBIx::Class::Schema::Loader from automatically adding InflateColumn::DateTime in Catalyst?

I am using Catalyst and DBIx::Class::Schema::Loader to create my model in Catalyst like so: script/myapp_create.pl model DB DBIC::Schema MyApp::Schema create=static overwrite_modifications=1 components=EncodedColumn dbi:mysql:mydb mydb…
Rob Boerman
  • 2,148
  • 14
  • 21
6
votes
2 answers

How do I add relationships at runtime using DBIx::Class and Catalyst?

In the application I am building, users can specify relationships between tables. Since I only determine this at runtime, I can't specify has_many or belongs_to relationships in the schema modules for startup. So given two tables; system and place,…
Joe
  • 61
  • 2
6
votes
3 answers

Less verbose debug screen in Catalyst?

in my stage server I would like to activate the debug so the clients can find errors for themselves before the app goes to the production server. BUT I only want the first part of the message, not the Request, or the Session Data. For example:…
Nacho B
  • 1,573
  • 1
  • 12
  • 16
6
votes
1 answer

How to get element from array in Template-Toolkit?

[% a = ['one', 'two', 'four'] %] [% a.1 %] # it prints two. OK! But when I want this: [% a = ['one', 'two', 'four'] %] [% n = 1 %] [% a.n %] # it doesn't work How can I use var n in order to get defined element from array?
edem
  • 3,222
  • 3
  • 19
  • 45
6
votes
1 answer

Catalyst Template::Toolkit render output

I'm using Catalyst with Template::Toolkit as my templating system. I would like to be able to render specific parts of templates and then have them returned to me so I can store them in a variable. The Template::Toolkit documentation mentions that…
srchulo
  • 5,143
  • 4
  • 43
  • 72
6
votes
2 answers

How to properly use UTF-8-encoded data from Schema inside Catalyst app?

Data defined inside Catalyst app or in templates has correct encoding and is diplayed well, but from database everything non-Latin1 is converted to ?. I suppose problem should be in model class, which is such: use strict; use base…
w.k
  • 8,218
  • 4
  • 32
  • 55
6
votes
2 answers

How can I set the Cache-Control header for every response in Catalyst?

It seems that by default Catalyst does not output Cache-Control:, etc. headers. I know I can output them in a given controller method like this: $c->response->headers->last_modified(time); $c->response->headers->expires(time +…
derobert
  • 49,731
  • 15
  • 94
  • 124
5
votes
3 answers

Difference between uri_for and uri_for_action

What is the difference between $c->uri_for and $c->uri_for_action methods of Catalyst. Which one to use? And why?
user966588
5
votes
3 answers

Which Perl module should I use to generate a validating CRUD webform?

Has anyone successfully used something like DBIx::Class::WebForm or CatalystX-CRUD to automagically build a self-validating webform from a database table? I'm imagining a module that reads a database table schema, reads the constraints for each…
Will Sheppard
  • 3,272
  • 2
  • 31
  • 41
5
votes
3 answers

How can I use Catalyst and uri chaining with a REST interface?

I'm expecting to receive uri's like /user/*/account/* I've got a user function defined as sub user :Path('/user') :PathPart('') :ActionClass('REST' ) {} then sub user_GET :PathPart('user') Chained('/') CaptureArgs(1) { #do stuff } For…
jmcneirney
  • 1,374
  • 8
  • 23
5
votes
5 answers

Is it viable to start with Catalyst while learning Perl?

I'm not quite sure that this is on-topic (if it isn't, I'll delete it ASAP =)). I've decided to start teaching myself Perl and how to use it for web development. I've done the same about a year ago with Python, and although I'm not an expert (I…
pcalcao
  • 15,789
  • 1
  • 44
  • 64
5
votes
3 answers

Why do we use Catalyst's Context Object? What is its purpose?

I was thinking that I don't really understand why just about everything in catalyst uses the context object. Seems that just about everything starts with my ( $self, $c ) = @_; we wrap DBIC with a catalyst model and end up…
xenoterracide
  • 16,274
  • 24
  • 118
  • 243
1 2
3
34 35