Re: a2c controller method names

2009-01-02 Thread David Ihnen
Mark Hedges wrote: On Thu, 1 Jan 2009, Mark Hedges wrote: Regarding your comment about inheritance vs. references - something I hadn't thought much about. A) I need to prefix all my internal method names with 'a2c_' to stay out of the controller namespace. B) You can't have any controller s

Re: a2c controller method names

2009-01-02 Thread David Ihnen
Mark Hedges wrote: I wonder how easy it would be to add controller subroutine attributes for which ones are allowed or not, ala Catalyst, instead of the controller having to provide an 'allowed_methods' method. Sounds like something JSON::RPC::Server::CGI does with :private and :public modifi

Re: a2c controller method names

2009-01-02 Thread Mark Hedges
On Fri, 2 Jan 2009, David Ihnen wrote: > Mark Hedges wrote: > > I wonder how easy it would be to add controller > > subroutine attributes for which ones are allowed or not, > > ala Catalyst, instead of the controller having to > > provide an 'allowed_methods' method. > > > > It would have been n

Re: a2c controller method names

2009-01-02 Thread Mark Hedges
> > On Thu, 1 Jan 2009, Mark Hedges wrote: Talking to myself > > again. I think I can make it work either way. > > Apache2::Controller won't use Apache2::Request as a > > base, but it will still instantiate the Apache2::Request > > object and put it in $self->{r}. Then if you want to > > use Apac

Apache::DBI / connect_on_init not setting dbi_connect_method but later connect() calls do

2009-01-02 Thread Marinos Yannikos
Hi, I'm trying to initiate connections in startup.pl for later use (mod_perl 1.xx): (startup.pl): use Apache::DBI; ... Apache::DBI->connect_on_init( 'dbi:Pg:dbname=mydb;host=myhost;port=5432', 'nobody',''); Later, I am attempting to reuse these connections in an Apache::Registry

Re: HTTP Response Headers fixup

2009-01-02 Thread Torsten Foertsch
On Thu 01 Jan 2009, André Warnier wrote: > It works perfectly, even without having the filter remove itself > (which I did not know how to do). http://perl.apache.org/docs/2.0/api/Apache2/Filter.html#C_remove_ Torsten -- Need professional mod_perl support? Just hire me: torsten.foert...@gmx.net

Re: Apache::DBI / connect_on_init not setting dbi_connect_method but later connect() calls do

2009-01-02 Thread Philip M. Gollucci
Apache::DBI->connect_on_init( 'dbi:Pg:dbname=mydb;host=myhost;port=5432', 'nobody',''); Can this be avoided somehow so that only 1 connection is initiated and reused? Is my DBI(1.53) or Apache::DBI(1.04) too old? Is it a bad idea to set dbi_connect_method explicitly in startup.p

Re: Apache::DBI / connect_on_init not setting dbi_connect_method but later connect() calls do

2009-01-02 Thread Philip M. Gollucci
Apache::DBI->connect_on_init( 'dbi:Pg:dbname=mydb;host=myhost;port=5432', 'nobody',''); Can this be avoided somehow so that only 1 connection is initiated and reused? Is my DBI(1.53) or Apache::DBI(1.04) too old? Is it a bad idea to set dbi_connect_method explicitly in startup.p

Quotes in uploaded filenames are not parsed correctly.

2009-01-02 Thread Miles Crawford
When you handle a multipart/form-data post with libapreq quotes in filenames are mishandled. For example, a post that includes: Content-Disposition: form-data; name="foo"; filename="break"here.jpg" Will result in a filename of just 'break'. To reproduce, set up a test following the snippets bel

Re: Quotes in uploaded filenames are not parsed correctly.

2009-01-02 Thread Adam Prime
Miles Crawford wrote: When you handle a multipart/form-data post with libapreq quotes in filenames are mishandled. For example, a post that includes: Content-Disposition: form-data; name="foo"; filename="break"here.jpg" Isn't that a malformed header? I would think that the internal '"' shou

Re: Quotes in uploaded filenames are not parsed correctly.

2009-01-02 Thread Miles Crawford
I agree it looks bogus, but safari and firefox send the header in that format. Not sure about IE since Windows does not allow files with a " in the name. I looked over the Content-Disposition header RFC but it does not seem to address escaping directly. Either way, it seems that this format is a