Re: [Catalyst] Multiple chain sources?

2010-11-22 Thread David Schmidt
On Mon, Nov 22, 2010 at 6:15 AM, Matthew Braid catal...@mdb.id.au wrote: Hi all, Just wondering - is it possible for an action to have multiple chain paths? I'd like my site to have a path like /user/N/profile (/user/N being a chain path, /profile being an end node off that path), but also

Re: [Catalyst] Multiple chain sources?

2010-11-22 Thread David Schmidt
On Mon, Nov 22, 2010 at 9:24 AM, David Schmidt davew...@gmx.at wrote: On Mon, Nov 22, 2010 at 6:15 AM, Matthew Braid catal...@mdb.id.au wrote: Hi all, Just wondering - is it possible for an action to have multiple chain paths? I'd like my site to have a path like /user/N/profile (/user/N

Re: [Catalyst] Re: Trying out FormHandler, running into maketext error

2010-11-22 Thread Hernan Lopes
will trilich, are you using widget type submit ? try to replace with type = 'Submit' Hernan Lopes On Mon, Nov 22, 2010 at 1:38 AM, John Anderson geneh...@genehack.orgwrote: On Nov 21, 2010, at 10:26 PM, will trillich wrote: Pooh. Still no luck. When we try a more more Moose-y approach, we

[Catalyst] Begginer's question about application structure

2010-11-22 Thread Martin Bendix
Hi, As a Perl and Catalyst novice, I have recently completed the online Catalyst tutorial, and read the Definitive Guide to Catalyst. However, I have a few questions about the basic structure of a thin controller, fat model application. I'd like to take my learning to the next stage by

Re: [Catalyst] Re: Trying out FormHandler, running into maketext error

2010-11-22 Thread will trillich
From %ENV there are only two LANG* keys: 'LANG' = 'en_US' 'LANGUAGE' = 'en_US:en_GB:en' Looking at the docs for HTML::FormHandler::TraitFor::I18N it sure looks flexible for moving toward a multi-language webapp, but when we just want a quick proof-of-concept, we'd hope that there are some

Re: [Catalyst] Re: Trying out FormHandler, running into maketext error

2010-11-22 Thread will trillich
Our form-class includes has_field 'submit' = ( widget = 'submit' ) Do you mean type='submit' instead of widget='submit'? Interesting that you'd think of this as a suspect. What's the rationale? On Mon, Nov 22, 2010 at 9:16 AM, Hernan Lopes hernanlo...@gmail.com wrote: will trilich,

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread woosley. xu.
Personally, as a novice too ^^, I like to keep the Model code clean enough, not to include too much functions like parameters check, which we can just create a controller action to accomplish. I got similar questions though: Some common functions, like date manipulation/formate, what is the

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread Ben van Staveren
Personally (and this does mean personally), I'd do it as follows: Your actual logic code (e.g. the whole deal of storing and retrieving things from the database) should be in a separate set of modules. Call those the 'backend' stuff. The main module here should be able to connect to the

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread Peter Edwards
Martin Bendix wrote: As a Perl and Catalyst novice, I have recently completed the online Catalyst tutorial, and read the Definitive Guide to Catalyst. However, I have a few questions about the basic structure of a thin controller, fat model application. I'd like to take my learning to

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread Martin Bendix
- Original Message From: Ben van Staveren benvanstave...@gmail.com To: The elegant MVC web framework catalyst@lists.scsys.co.uk Sent: Mon, 22 November, 2010 15:13:00 Subject: Re: [Catalyst] Begginer's question about application structure Personally (and this does mean personally),

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread Martin Bendix
Have a look at this article http://www.catalystframework.org/calendar/2007/14 which covers using Catalyst models externally. The code that goes with it is well out of date but should give you the general idea using an external DBIC model class. Access to the model from a batch script:

[Catalyst] Having problem with Catalyst::Controller::FormBuilder module with Catalyst 5.8

2010-11-22 Thread Cory Hollingsworth
Hello every one. I have a couple of Catalyst based web applications which I created about 2 years ago which work with Catalyst 5.7x, Catalyst::Controller::FormBuilder 0.05, and CGI::FormBuilder 3.0501. I would like to move these to a Catalyst 5.8 environment. I am expecting to have to do a

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread Sir Robert Burbridge
On 11/22/2010 09:17 AM, Martin Bendix wrote: Hi, As a Perl and Catalyst novice, I have recently completed the online Catalyst tutorial, and read the Definitive Guide to Catalyst. However, I have a few questions about the basic structure of a thin controller, fat model application. I'd like to

Re: [Catalyst] Re: Trying out FormHandler, running into maketext error

2010-11-22 Thread Hernan Lopes
will trillich, that error happens when i use has_field 'submit' = ( widget = 'submit' ) can you test your form with this instead: has_field 'submit' = (type = 'Submit', label = 'Submit', value='Submit', required = 0, ) i bet your error will go away On Mon, Nov 22, 2010 at 12:19 PM, will

Re: [Catalyst] Re: Trying out FormHandler, running into maketext error

2010-11-22 Thread will trillich
Ooh, very nice! Thanks so much, that's lots better now. Woo hoo! Yes indeed, the undef error - Unable to do maketext on: at /usr/local/share/perl/5.10.0/HTML/FormHandler/I18N.pm line 15. error has gone away thanks to tweaks to the SUBMIT button on the FormHandler definition. Was there something

Re: [Catalyst] Having problem with Catalyst::Controller::FormBuilder module with Catalyst 5.8

2010-11-22 Thread Tomas Doran
On 22 Nov 2010, at 16:41, Cory Hollingsworth wrote: Here is a very simple example of a Root.pm code which illustrates my problem: Start Perl Code package lookupreset::Controller::Root; use base 'Catalyst::Controller::FormBuilder'; use Moose; use namespace::autoclean; BEGIN { extends

Re: [Catalyst] Converting a GET request to a POST request

2010-11-22 Thread Tomas Doran
On 22 Nov 2010, at 17:44, Ronald J Kimball wrote: This works for JSON requests (e.g. application/json), but not for JSONP requests (e.g. text/javascript), because there is no Catalyst::Action::Deserialize::JSONP. I guess I could create one that extends Catalyst::Action::Deserialize::JSON...

Re: [Catalyst] Catalyst needs Advent Calendar Volunteers!

2010-11-22 Thread Steve
Hi, I have an Advent Calendar suggestion that I think could have a large audience - Using Catalyst with JQuery Themes/Themeroller. The reason I think it might find a good audience is simply that I think having a ready-to-use UI is possibly the biggest think keeping people from adopting

Re: [Catalyst] Query : Catalyst forward and relative path in CSS.

2010-11-22 Thread Tomas Doran
On 21 Nov 2010, at 16:10, Rohan M wrote: Although, the scripts are working but I'm facing two problems - 1) The $c-forward('controller/action') NOT working Do you not mean $c-forward('/controller/action'), which looks like a more reasonable private path ? Cheers t0m

Re: [Catalyst] Converting a GET request to a POST request

2010-11-22 Thread Ronald J Kimball
On Mon, Nov 22, 2010 at 12:53 PM, Tomas Doran bobtf...@bobtfish.net wrote: On 22 Nov 2010, at 17:44, Ronald J Kimball wrote: This works for JSON requests (e.g. application/json), but not for JSONP requests (e.g. text/javascript), because there is no Catalyst::Action::Deserialize::JSONP.  I

Re: [Catalyst] Catalyst needs Advent Calendar Volunteers!

2010-11-22 Thread Devin Austin
Hey Steve, Great, just for people's inbox's sake, if you have an article idea (that you don't want reviewed by the community at least), go ahead and just email me directly or pm me on IRC. Let's touch base and I can get you set up with what you need. -Devin On Mon, Nov 22, 2010 at 10:53 AM,

Re: [Catalyst] Catalyst needs Advent Calendar Volunteers!

2010-11-22 Thread Jason L. Froebe
When the advents are posted, can people make sure they put the catalyst version number that was used? I ask because your advent may be viewed a year or more later where it no longer works because catalyst (or some other dependency) changed. jason On Mon, Nov 22, 2010 at 1:13 PM, Devin Austin

Re: [Catalyst] Catalyst needs Advent Calendar Volunteers!

2010-11-22 Thread Devin Austin
On Mon, Nov 22, 2010 at 12:39 PM, Jason L. Froebe jason.fro...@gmail.comwrote: When the advents are posted, can people make sure they put the catalyst version number that was used? I ask because your advent may be viewed a year or more later where it no longer works because catalyst (or some

Re: [Catalyst] Having problem with Catalyst::Controller::FormBuilder module with Catalyst 5.8

2010-11-22 Thread Cory Hollingsworth
On 22 Nov 2010, at 16:41, Cory Hollingsworth wrote: Here is a very simple example of a Root.pm code which illustrates my problem: Start Perl Code package lookupreset::Controller::Root; use base 'Catalyst::Controller::FormBuilder'; use Moose; use namespace::autoclean; BEGIN { extends

[Catalyst] Re: Converting a GET request to a POST request

2010-11-22 Thread Aristotle Pagaltzis
* Ronald J Kimball rkimb...@pangeamedia.com [2010-11-22 18:50]: I want to convert a GET request to a POST request, inside my Catalyst app, before dispatching happens. For example, I want to take a request like: GET /foo?method=POSTbody={foo:1}content-type=text/javascript and convert it into

[Catalyst] Re: Converting a GET request to a POST request

2010-11-22 Thread Adam Sjøgren
On Mon, 22 Nov 2010 21:12:26 +0100, Aristotle wrote: * Ronald J Kimball rkimb...@pangeamedia.com [2010-11-22 18:50]: I want to convert a GET request to a POST request, inside my Catalyst app, before dispatching happens. [...] This is really, really, really bad. [...] So, what solution do

Re: [Catalyst] Converting a GET request to a POST request

2010-11-22 Thread Tomas Doran
On 22 Nov 2010, at 18:28, Ronald J Kimball wrote: It doesn't care what the request method is, as long as it's POST, PUT, OPTIONS, or DELETE. ;) No, it just doesn't care. If I create Catalyst::Action::Deserialize::JSONP, I'll still need to convert the GET request to a POST. That seems to

Re: [Catalyst] Multiple chain sources?

2010-11-22 Thread Eden Cardim
Matthew == Matthew Braid catal...@mdb.id.au writes: Matthew Hi all, Just wondering - is it possible for an action to Matthew have multiple chain paths? Matthew I'd like my site to have a path like /user/N/profile Matthew (/user/N being a chain path, /profile being an end node

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread Eden Cardim
Martin == Martin Bendix martinben...@yahoo.co.uk writes: Martin My model should be well separated from the controller. Martin Most, if not all of the application functionality should be Martin exposed via the model, so that the Catalyst controller only Martin needs to make simple

Re: [Catalyst] Begginer's question about application structure

2010-11-22 Thread Martin Bendix
From: Sir Robert Burbridge rburb...@cisco.com To: The elegant MVC web framework catalyst@lists.scsys.co.uk Sent: Mon, 22 November, 2010 17:20:16 Subject: Re: [Catalyst] Begginer's question about application structure I use DBIx::Class with multiple interfaces in the same app; this is the