Re: apache2 -t... can't find Apache.pm?

2006-02-05 Thread will trillich
On 2/5/06, Ken Perl <[EMAIL PROTECTED]> wrote: > comment out the PerlModule Apache in the file > /etc/apache2/mod-enalbed/perl.conf, I guess Apache.pm isn't useful for > apache2, it is used for apache1.x. > when you install apache2 on debian 3.1, you reserved the old config > file, right? so the li

Re: How to set Content-Type header on custom_response()?

2006-02-05 Thread Foo Ji-Haw
How about returning a self-designed error page, instead of using Apache's? - Original Message - From: "Geoffrey Young" <[EMAIL PROTECTED]> To: "Andrew Ho" <[EMAIL PROTECTED]> Cc: "mod_perl List" Sent: Sunday, February 05, 2006 2:24 AM Subject: Re: How to set Content-Type header on custom

Re: Clarifying Q: Usage suggestions: caching DB metadata with mod_perl?

2006-02-05 Thread Jonathan
Well I couldn't use Data::FormValidator for my exact needs There were too many if/else conditions I needed to implement into my form class that I couldn't do with its constraint and dependency system easily ( a bunch of multiple-field validations that would even change the valid repsonse s

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread Derek Robson
ok so now i have tried using warn and i get check1 and check2 but not check3. I am thinking that it must be something in my setup rather than my code. in my httpd.conf I have... Alias /perl/ /var/www/perl/ PerlModule Apache::PerlRun PerlModule DBI PerlModule DBD::mysql SetHandler perl-

For those familiar with HTML::TreeBuilder and HTML::Element

2006-02-05 Thread Boysenberry Payne
Hello, I'm trying to get upper case html with HTML::TreeBuilder via HTML::Element->as_HTML via: # Build HTML Tree $self->{tree} = HTML::TreeBuilder->new(); my $tree = $self->{tree}; # Parse HTML $tree->parse( $html ); $tree->eof; my $new_html = $tree->as_HTML( '<>&', "", {} ); $html was: Tes

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread Michael Peters
Derek Robson wrote: > > > print "check1"; > my $dbArgs = { RaiseError => 1, AutoCommit => 0 , TraceLevel => 3 , > PrintError => 1 }; > print "check2"; > my $dbh = DBI->connect("DBI:mysql:database=answerguy;", > "robsonde", "ur4xgod",$dbArgs ) > or die "Cannot con

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread Derek Robson
print "check1"; my $dbArgs = { RaiseError => 1, AutoCommit => 0 , TraceLevel => 3 , PrintError => 1 }; print "check2"; my $dbh = DBI->connect("DBI:mysql:database=answerguy;", "robsonde", "ur4xgod",$dbArgs ) or die "Cannot connect to database: $!"; print "check3"

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread Michael Peters
John Doe wrote: > An easy quick and dirty way to find out where your code stucks is by putting > warns (go to the error log) or prints (go to browser) after every statement > in the code. warns are nice cause they go to the error log rather than waiting on the browser to receive and display.

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread John Doe
> how can i check its not a connection timeout problem? If your query takes longer than # Timeout: The number of seconds before receives and sends time out. Timeout 300 in the httpd.conf file the connection is closed by the server. But this is rather inprobable I think; you could run the db qu

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread Derek Robson
how can i check its not a connection timeout problem? is there a very basic example online of DBI under mod perl? At 04:31 a.m. 6/02/2006, John Doe wrote: Jonathan Vanasco am Sonntag, 5. Februar 2006 00.27: > Try: > > my $dbArgs = { RaiseError => 1, AutoCommit => 0 , TraceLevel => 3 }; > m

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread Derek Robson
same result, still no errors. At 05:23 p.m. 5/02/2006, Malcolm J Harwood wrote: On Saturday 04 February 2006 02:45 am, Derek Robson wrote: > DBI->connect("DBI:mysql:database=answerguy;host=elmo.elmo.theanswerguy.co.n >z", "robsonde", "ur4xgod", I don't know what the problem with your code is,

Re: Clarifying Q: Usage suggestions: caching DB metadata with mod_perl?

2006-02-05 Thread Michael Peters
Jonathan wrote: > > On Feb 4, 2006, at 7:03 PM, RJ Herrick wrote: > >> In validating my form input I look at my DB tables to see what types >> of input they will accept (valid values, maxlength, NULL ok, etc). >> This data is about the database, not the values coming in off the >> forms. It

apache2 -t... can't find Apache.pm?

2006-02-05 Thread will trillich
okay -- on a debian/stable system with apache2/mod-perl2, my apache2 can't find Apache.pm in /usr/lib/perl5 even tho it's right there! config includes "PerlModule Apache2" before including conf.d of course: # apache2 -t Syntax error on line 3 of /etc/apache2/conf.d/Handler.conf:Can't locate Apache

Re: MP2 dir_config

2006-02-05 Thread Frank Wiles
On Sun, 5 Feb 2006 23:01:25 +0800 Ken Perl <[EMAIL PROTECTED]> wrote: > sub handler { > my $r = shift; > my $s = Apache2::ServerUtil->server; > > $s->dir_config('WRoot'); > $r->dir_config('WConfig'); > } > > which module api doc that I could find description about

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread John Doe
Jonathan Vanasco am Sonntag, 5. Februar 2006 00.27: > Try: > > my $dbArgs = { RaiseError => 1, AutoCommit => 0 , TraceLevel => 3 }; > my$dbh = DBI->connect( $db, $dbUser, $dbPass , $dbArgs ); > > while you `tail -f` the errorlog ( /usr/local/apache2/log/error_log > on my system ) > > the trace

Re: modperl and DBI or DBD with mysql

2006-02-05 Thread Malcolm J Harwood
On Saturday 04 February 2006 02:45 am, Derek Robson wrote: > DBI->connect("DBI:mysql:database=answerguy;host=elmo.elmo.theanswerguy.co.n >z", "robsonde", "ur4xgod", I don't know what the problem with your code is, but you probably should change your password now that you've told everyone. :) >

MP2 dir_config

2006-02-05 Thread Ken Perl
sub handler { my $r = shift; my $s = Apache2::ServerUtil->server; $s->dir_config('WRoot'); $r->dir_config('WConfig'); } which module api doc that I could find description about the two dir_config? I want to know more info about them. -- perl -e 'print unpack(u,"62

Re: Clarifying Q: Usage suggestions: caching DB metadata with mod_perl?

2006-02-05 Thread Jonathan
On Feb 4, 2006, at 7:03 PM, RJ Herrick wrote: In validating my form input I look at my DB tables to see what types of input they will accept (valid values, maxlength, NULL ok, etc). This data is about the database, not the values coming in off the forms. It will stay the same until I alter