Re: [Catalyst] Which Form Validation Libs?

2010-11-30 Thread Mike Raynham
On 30/11/10 03:34, Eric Berg wrote: I see that there are a number of form validation libraries that purport to work with Catalyst. I've been using CGI::Formbuilder for years and have been relatively happy with it. I need something for my new Catalyst app. I have already created my forms in my

Re: [Catalyst] Which Form Validation Libs?

2010-11-30 Thread David Schmidt
another great module which from my perception is used the most lately is HTML::FormHandler http://search.cpan.org/~gshank/HTML-FormHandler-0.32005/ greetings david On Tue, Nov 30, 2010 at 9:24 AM, Mike Raynham catal...@mikeraynham.co.uk wrote: On 30/11/10 03:34, Eric Berg wrote: I see that

Re: [Catalyst] Which Form Validation Libs?

2010-11-30 Thread Hernan Lopes
formhandler and formbuilder have some syntax similarities. shouldnt be hard to move from one to the other. Just in case you are curiousm, here are some examples: FormBuilder: http://www.formbuilder.org/tutor/index.pl?c=1s=5 FormHandler:

Re: [Catalyst] Which Form Validation Libs?

2010-11-30 Thread Ashley Pond V
HTML::FormHandler Chiming in: FormHandler has been getting the most questions lately, IIRC, but I suspect FormFu is more often used. It has its own excellent mailing list (made excellent by the main dev, Carl Franks, who is very responsive and helpful) so the questions don't tend to end up here.

Re: [Catalyst] Re: superuser switch-user session function?

2010-11-30 Thread Peter Karman
will trillich wrote on 11/29/2010 05:37 PM: Aha! It looks like a sneaky, evil, wrong, mean, horrid way to switch-user in the middle of a session is to $c-session-{__user}{id} = $new_id_here; # since id = PK But that's undoubtedly bad form of the worst kind. What's the canonical

Re: [Catalyst] Which Form Validation Libs?

2010-11-30 Thread Peter Karman
Eric Berg wrote on 11/29/2010 09:34 PM: You guys got any recommendations? Rose::HTML::Objects -- Peter Karman . http://peknet.com/ . pe...@peknet.com ___ List: Catalyst@lists.scsys.co.uk Listinfo:

[Catalyst] C::E::HTTP::PreFork deployment

2010-11-30 Thread Edmund von der Burg
Hello, Currently I run several Catalyst apps under lighttpd using fastcgi. I'd like to switch to them being HTTP::Prefork. Are there any sample setups that I can refer to - especially that illustrate: * several apps on one IP address (hostname based routing) * restarting app when new code is

Re: [Catalyst] Re: superuser switch-user session function?

2010-11-30 Thread Hernan Lopes
Indeed, i think it should login as a new user not changing the actual session. maybe something like: admin clicks login as joeuseropen a new browser window as adminverify its admin and re-login as a new user. register on session user is admin so he can log back in. Then add button terminate

[Catalyst] FormHandler -- pro or con?

2010-11-30 Thread will trillich
Anybody else *dissing* FormHandler? We've started developing based on FormHandler lately and haven't had troubles... yet? On Tue, Nov 30, 2010 at 5:26 AM, Shlomi Fish shlo...@iglu.org.il wrote: I can recommend *against* HTML-FormHandler. For my day job's Perl and Catalyst project, we

Re: [Catalyst] Which Form Validation Libs?

2010-11-30 Thread Steve
My guess is that FormHandler is getting the attention that it is is due to two major things. First of all, it is Moose based - like Catalyst. Secondly, the documentation of FormHandler seems more complete. Unless the docs for FormFu have been updated recently (past 6 months or so), the

Re: [Catalyst] C::E::HTTP::PreFork deployment

2010-11-30 Thread Ashley Pond V
On Tue, Nov 30, 2010 at 7:04 AM, Edmund von der Burg e...@ecclestoad.co.uk wrote: Hello, Currently I run several Catalyst apps under lighttpd using fastcgi. I'd like to switch to them being HTTP::Prefork. A very incomplete answer but I'd suggest adding PSGI/Starman to the list of things you

Re: [Catalyst] FormHandler -- pro or con?

2010-11-30 Thread Hernan Lopes
Formhandler works like a charm, does many useful checks and you wont have any trouble with it. i have been using it for a while without any problem. As for the memory leaks, it can affect you when resources are limited or when you are running out of ram. (no idea if there are any leaks on

[Catalyst] DBIx::Class many_to_many relationship

2010-11-30 Thread linuxsupport
Hi, I am new to Catalyst and DBIx::Class, trying to use many_to_many relationship. I have 3 tables, users, user_groups, and group, table structure and relationship are setup as follows. User.pm __PACKAGE__-add_columns( id, { data_type = integer, is_nullable = 0 }, username, { data_type

Re: [Catalyst] DBIx::Class many_to_many relationship

2010-11-30 Thread Steve
I recommend you create a 'Example::Schema::ResultSet::Group' resultset class. Presumably you already have a 'Result' directory where your table classes reside, so create a ResultSet directory (if you don't already have one). Look here:

Re: [Catalyst] FormHandler -- pro or con?

2010-11-30 Thread Sir Robert Burbridge
On 11/30/2010 10:34 AM, will trillich wrote: Anybody else *dissing* FormHandler? We've started developing based on FormHandler lately and haven't had troubles... yet? On Tue, Nov 30, 2010 at 5:26 AM, Shlomi Fish shlo...@iglu.org.il mailto:shlo...@iglu.org.il wrote: I can recommend

Re: [Catalyst] DBIx::Class many_to_many relationship

2010-11-30 Thread Emmanuel OTTON
Le 30 nov. 2010 à 17:02, linuxsupport a écrit : Hi, I am new to Catalyst and DBIx::Class, trying to use many_to_many relationship. I have 3 tables, users, user_groups, and group, table structure and relationship are setup as follows. User.pm __PACKAGE__-add_columns( id, { data_type =

Re: [Catalyst] FormHandler -- pro or con?

2010-11-30 Thread Zbigniew Lukasiak
On Tue, Nov 30, 2010 at 4:55 PM, Sir Robert Burbridge rburb...@cisco.com wrote: To mitigate the awkwardness I felt about the API, use a pure-module approach (every form is a separate package/module, that inherits from a base form that's all rigged up the way I want it, along with a few really

Re: [Catalyst] DBIx::Class many_to_many relationship

2010-11-30 Thread linuxsupport
Thanks Emmanuel, worked as I wanted to, much appreciated. On Tue, Nov 30, 2010 at 10:25 PM, Emmanuel OTTON ot...@mines-albi.frwrote: Le 30 nov. 2010 à 17:02, linuxsupport a écrit : Hi, I am new to Catalyst and DBIx::Class, trying to use many_to_many relationship. I have 3 tables,

Re: [Catalyst] DBIx::Class many_to_many relationship

2010-11-30 Thread Kutbuddin Doctor
In the classes you have written, you are using the same name for the many_to_many method from (group) in User.pm as you have used in method between UserGroup to Group. __PACKAGE__-many_to_many(group = 'usergroups', 'group'); I have seen this cause problems in my hands when using it for User

RE: [Catalyst] Overriding Catalyst::View::TT WRAPPER

2010-11-30 Thread Mesdaq, Ali
Worked like a charm. I agree that this is a cleaner way as well. However it might be useful if we had the ability to override added to catalyst something like $c-stash ( WRAPPER = undef, template = 'src/mypage.tt2', ); Or something along those lines. Thanks,

Re: [Catalyst] Overriding Catalyst::View::TT WRAPPER

2010-11-30 Thread Bill Moseley
On Mon, Nov 29, 2010 at 5:27 PM, Sam Kaufman samuel.c.kauf...@gmail.comwrote: I've found the easiest way is to have some logic in your wrapper: something like this: [% IF no_wrapper; content; ELSE; content WRAPPER site/html + site/layout; END; %] I tend to use a CASE statement in

Re: [Catalyst] Overriding Catalyst::View::TT WRAPPER

2010-11-30 Thread David Stevenson
On 1 Dec 2010, at 00:39, Bill Moseley wrote: Yes, but I also allow templates to specify their layout. So for an action /foo/bar I might have /foo/bar.tt and in bar.tt: [% page.layout = 'cms'; # override default layout %] Yes, that's what I do. The template is deciding the view. IMO