ANNOUNCE: Apache::ASP v2.03
Hey, Big changes for Apache::ASP! GPL licensing and the new http://www.apache-asp.org web site. A lot of consideration went behind GPL, and I know there are pros & cons to any license. Note I will be gone on vacation for a couple weeks so hopefully others on the list will be able to pick up my slack while I'm gone :) CHANGES for 2.03: +License change to GPL. See LICENSE section. +Setup of http://www.apache-asp.org site, finally! -get rid of Apache::ASP->Loader() warning message for perl 5.6.0 DESCRIPTION Apache::ASP provides an Active Server Pages port to the Apache Web Server with Perl as the host scripting language. Apache::ASP allows a developer to create dynamic Web applications with session management and embedded Perl code. There are also many powerful extensions, including XML taglibs, XSLT rendering, and new events not originally part of the ASP API. To easily install, try CPAN's install Bundle::Apache::ASP -- Joshua _ Joshua Chamas Chamas Enterprises Inc. NodeWorks >> free web link monitoring Huntington Beach, CA USA http://www.nodeworks.com1-714-625-4051
RE: Help Embperl
No problem: Jeff's Stock Page [$ if $ENV{REQUEST_METHOD} eq 'GET' $] This is a GET request [$ elsif $ENV{REQUEST_METHOD} eq 'POST' $] This is a POST request [$ else $] This is not GET and not POST [$ endif $] Thanks, Jeff On Sat, 5 Aug 2000, Jason Bodnar wrote: > Please send the file for the url you're getting the error with. > > On 05-Aug-2000 Jeff Smelser wrote: > > I got EMbperl to compile. It when I did make test, everything went great. > > OK's down the line. I set up apache with: > > > > > > SetHandler perl-script > > PerlHandler HTML::Embperl > > > > > > This is what apache says when I restarted it: > > > > [10843]ERR: 25: Line 1: Error > > [Sat Aug 5 16:10:00 2000] [notice] Apache/1.3.9 (Unix) (Red Hat/Linux) > > mod_perl/1.21 configured -- resuming normal operations > > > > This is what it says when I test is with test.html: > > > > Bareword found where operator expected at /home/httpd/perl/test.html line > > 3, near "Jeff's" > > (Missing operator before Jeff's?) > > Bareword found where operator expected at /home/httpd/perl/test.html line > > 5, near "/TITLE> > > > (Might be a runaway multi-line // string starting on line 4) > > (Missing operator before HEAD?) > > Scalar found where operator expected at /home/httpd/perl/test.html line 7, > > at end of line > > (Missing operator before ?) > > [Sat Aug 5 16:10:07 2000] [error] syntax error at > > /home/httpd/perl/test.html line 2, near "HEAD" > > > > What did I miss? > > > > Running embpexec.pl works fine on the same file I am running through > > apache. > > > > Thanks, > > Jeff > > > > > > > > -- > Jason Bodnar > [EMAIL PROTECTED] >
problem with DBD::Oracle and so
i know this is been discussed before.. but i could not easily find them in the archive.. I always get the following err: Can't load '/perl5.6.0/lib/site_perl/5.6.0/i686-linux/auto/DBD/Oracle/Oracle.so' for module DBD::Oracle: libclntsh.so.8.0: cannot open shared object file: No such file or directory at /home/perlish/apps/perl5.6.0/lib/5.6.0/i686-linux/DynaLoader.pm line 200. when try to start apache. any hint?
RE: Help Embperl
Please send the file for the url you're getting the error with. On 05-Aug-2000 Jeff Smelser wrote: > I got EMbperl to compile. It when I did make test, everything went great. > OK's down the line. I set up apache with: > > > SetHandler perl-script > PerlHandler HTML::Embperl > > > This is what apache says when I restarted it: > > [10843]ERR: 25: Line 1: Error > [Sat Aug 5 16:10:00 2000] [notice] Apache/1.3.9 (Unix) (Red Hat/Linux) > mod_perl/1.21 configured -- resuming normal operations > > This is what it says when I test is with test.html: > > Bareword found where operator expected at /home/httpd/perl/test.html line > 3, near "Jeff's" > (Missing operator before Jeff's?) > Bareword found where operator expected at /home/httpd/perl/test.html line > 5, near "/TITLE> >(Might be a runaway multi-line // string starting on line 4) > (Missing operator before HEAD?) > Scalar found where operator expected at /home/httpd/perl/test.html line 7, > at end of line > (Missing operator before ?) > [Sat Aug 5 16:10:07 2000] [error] syntax error at > /home/httpd/perl/test.html line 2, near "HEAD" > > What did I miss? > > Running embpexec.pl works fine on the same file I am running through > apache. > > Thanks, > Jeff > > > -- Jason Bodnar [EMAIL PROTECTED]
Re: ignore header_only()?
Ken Williams wrote: > I know it was ages ago when you sent this patch, but what's the > rationale for having $r->sent_header() return 1 when it hasn't sent the > header? I didn't want to break anything. I'm hoping that people using sent_header are just checking for true, not for 1. (That's the way the mod_perl core does it.) > Shouldn't it be fixed to return 1 or 0 according to whether the > header has actually been sent? I'll let Doug decide. IMHO sent_header is the wrong method name. The current function should be called need_headers. (When PerlSendHeader is on, you don't need to send headers.) A new function should be added to let you know if the headers have already been sent. > If need be, perhaps it could distinguish like this: > >undef - headers have not been sent (PerlSendHeader on) >0 - headers have not been sent (PerlSendHeader off) >1 - headers have already been sent (PerlSendHeader off) >2 - headers have already been sent (PerlSendHeader on) That might break code because you're changing the truth values. My code didn't need to differentiate between the two unsent cases which is why I'm only returning 3 different values. - Ken
ANNOUNCE: mod_perl Guide v. 1.25
The uploaded file Apache-mod_perl_guide-1.25.tar.gz has entered CPAN as file: $CPAN/authors/id/S/ST/STAS/Apache-mod_perl_guide-1.25.tar.gz size: 520586 bytes md5: 7b1d0c0022139936b6b6e47cb295 The online version is at http://perl.apache.org/guide/ The PDF version is at http://perl.apache.org/guide/mod_perl_guide.pdf.gz CHANGES: * License: People asked me to redistribute mod_perl Guide in other ways than just mirroring the mod_perl site. Therefore I've licensed the guide under GPL and included the required info in the CPAN package. * perl: o added "Using Non-Hardcoded Configuration Module Names" (Chris Winters) * debug: o updated: "How can I find out if a mod_perl code has a memory leak" o rewritten: Handling the 'User pressed Stop button' case Detecting Aborted Connections The Importance of Cleanup Code Critical Section Safe Resource Locking and Cleanup Code * config: o added a sub header "Running CGI, PerlRun, and Registry Scripts located in the same Directory" to make the info more prominent to find. (Ron Pero) o PerlAddVar info was added * control o "Swapping Prevention" rewritten from scratch and moved from performance chapter to control chapter (Ed Phillips, Barrie Slaymaker, Joshua Chamas) o "Preparing for Machine Reboot" -- added a section describing the chkconfig(8) use (Andreas Koenig) * porting: o the wrong suggested solution to the nested sub problem was spotted!!! (Hunter Monroe, Hailei Dai) it's fixed now. o update: "Terminating requests and processes, the exit() and child_terminate() functions" -- under perl5.6 you don't need to override exit anymore! (Doug, Eric Cholet) o s/PerlTaintMode/PerlTaintCheck/ (Gunther Birznieks) * review: o Mark Summerfield has reviewed these chapters: modules, browserbugs, security and start. * performance: o "CGI.pm vs Apache::Request" and "Apache::args vs Apache::Request::param" were merged into a single section called: "Apache::args vs Apache::Request::param vs CGI::param" o The first example showing the use of ab was corrected (Joe Schaefer) o rewritten: + Apache::Registry PerlHandler versus Custom PerlHandler + Keeping the Shared Memory Limit + Limiting the Size of the Processes + Limiting Other Resources Used by Apache Child Processes * modules: o "Apache::GTopLimit - Limit Apache httpd processes" merged into performance chapter. o Apache::PerlVINC configuration corrected (Patrick) * Minor corrections: o config (Carl Hansen, Ron Pero, Jeff Chan, Cliff Rayman, Marcel Grunauer) o control (Marcel Grunauer) o debug (Marcel Grunauer) o install (Ron Pero) o snippets (Ask Bjoern Hansen, Chris Nokleberg) o perl (Will Trillich, Cliff Rayman, Jason Rhinelander) o porting (Ged Haywood) _ Stas Bekman JAm_pH -- Just Another mod_perl Hacker http://stason.org/ mod_perl Guide http://perl.apache.org/guide mailto:[EMAIL PROTECTED] http://perl.org http://stason.org/TULARC http://singlesheaven.com http://perlmonth.com http://sourcegarden.org
Help Embperl
I got EMbperl to compile. It when I did make test, everything went great. OK's down the line. I set up apache with: SetHandler perl-script PerlHandler HTML::Embperl This is what apache says when I restarted it: [10843]ERR: 25: Line 1: Error [Sat Aug 5 16:10:00 2000] [notice] Apache/1.3.9 (Unix) (Red Hat/Linux) mod_perl/1.21 configured -- resuming normal operations This is what it says when I test is with test.html: Bareword found where operator expected at /home/httpd/perl/test.html line 3, near "Jeff's" (Missing operator before Jeff's?) Bareword found where operator expected at /home/httpd/perl/test.html line 5, near "/TITLE>
Re: Apache::ASP Response Redirect question
"G.W. Haywood" wrote: > > Hi there, > > On Sun, 6 Aug 2000, Rod Butcher wrote: > > > Can anybody please tell me whether the following internal redirect > > causes the new URL to be sent back to the browser which then asks for > > foo.htm to be served up, or does Apache simply serve up foo.htm > > automatically ? > > I'll field this one because Josh is busy going to Sweden this weekend. > > > The comments in ASP.PM are very cryptic. > Almost gone Ged ... not soon enough though ;) $Response->Redirect() is an external redirect, $Server->Transfer() is an internal redirect and is what you are looking for Rod. Please read the docs fully to know how you can use ASP maximally. The distribution README like Ged said, or the site http://www.apache-asp.org. -- Joshua
Re: On the fly "do" (require)
Hi there, On Wed, 26 Jul 2000 [EMAIL PROTECTED] wrote: > I got some problem migrating me CGI to mod_perl. I do not know if I understand your question, but you could try looking at Apache::Registry to get your CGI scripts to work under mod_perl. Also look at http://perl.apache.org/guide 73, Ged.
Re: error from modper ??
Hi there, On Fri, 4 Aug 2000, Aaron Patterson wrote: > Try restarting apache. Try reading your code instead. Things like opening files without being careful to specify the full pathname can cause this kind of stuff. A script works while you're testing from the command line, but when it runs in a different environment (mod_perl supplies a different environment) the fun begins. > I would apprectiate any corrections, and any more info on the > subject!! http://perl.apache.org/guide
Re: ignore header_only()?
Ken Fox wrote: > I was using $request->sent_header and found out that it's > not terribly useful if PerlSendHeader is off -- sent_header > always returns 1. I changed mod_perl_sent_header so that > it returns 0, 1 or 2: > > 0 - headers have not been sent (PerlSendHeader on) > 1 - headers have not been sent (PerlSendHeader off) > 2 - headers have already been sent I know it was ages ago when you sent this patch, but what's the rationale for having $r->sent_header() return 1 when it hasn't sent the header? Shouldn't it be fixed to return 1 or 0 according to whether the header has actually been sent? If need be, perhaps it could distinguish like this: undef - headers have not been sent (PerlSendHeader on) 0 - headers have not been sent (PerlSendHeader off) 1 - headers have already been sent (PerlSendHeader off) 2 - headers have already been sent (PerlSendHeader on) But I'd rather just have it return 1 or 0, and have a seperate method that tells you whether PerlSendHeader is on or off.
Re: follow-up: very strange bug w/ tainting
Hi there, On Wed, 26 Jul 2000, Alex Algard wrote: > More strange stuff [snip] FYI, Test.pm is just an empty file, so it > certainly shouldn't cause any harm. A couple of months ago I had a problem where a *very* simple script would crash Apache 1.3.12/modperl 1.24 no matter what I did. In the end I *renamed* it and the problem went away. Until I renamed it, the script was called... Test.pm 73, Ged.
Re: ignore header_only()?
> Ken Fox wrote: > > I was using $request->sent_header and found out that it's > > not terribly useful if PerlSendHeader is off -- sent_header > > always returns 1. I changed mod_perl_sent_header so that > > it returns 0, 1 or 2: > > > > 0 - headers have not been sent (PerlSendHeader on) > > 1 - headers have not been sent (PerlSendHeader off) > > 2 - headers have already been sent > > Is this the right list for change proposals? Should I re-submit my > patch? Yes it's the right list, and no, no need to resubmit. Personally I only commit bug fixes, and Doug looks at new features. He'll get around to it, he's just a bit busy at the moment. Thanks, -- Eric
Re: Apache::PerlVINC makes Apache segfault
> [Cc to Stas as the example in the guide is wrong, and Dave explains > the correct way] > > On Mon, Jul 31, 2000 at 03:42:18PM -0400, Dave Moore took time to write: > > > > duh...now that i've had some more coffee...the line: > > > > PerlVersionINC On > > > > must come before the PerlINC statement. PerlINC wont store that path > > unless PerlVersionINC is On. > > Ok, that corrected my problem, thanks a lot Dave. Thanks Patrick. I've udpated the guide. The man page should be corrected as well. > > dave > > On Mon, 31 Jul 2000, Dave Moore wrote: > > > > > you arent doing anything wrong. you probably just need to upgrade to the > > > latest version of Apache::ExtUtils. this is not the same ExtUtils that > > > comes with mod_perl 1.24. you will have to get it from the latest cvs > > > snapshot of mod_perl. you will also have to remake/install PerlVINC after > > > you install ExtUtils. see if that helps. > > > > > > On Sat, 29 Jul 2000, Patrick wrote: > > > > > > > Hi all, > > > > > > > > (debian potato) > > > > apache-ssl : 1.3.9.13-2 > > > > modperl : 1.21.2309-1 > > > > perl : 5.005 > > > > Apache::PerlVINC : 0.01 compiled by myself > > > > > > > > As recommended in the guide, i'm trying to use Apache::PerlVINC since > > > > I have 3 virtualhosts, and the same sets of modules for all three (same >namespace), in > > > > three separate directories (one production, two developpments). > > > > > > > > So I have in httpd.conf > > > > > > > > PerlModule Apache::PerlVINC > > > > PerlINC /opt/anciens/membres > > > > PerlVersionINC On > > > > PerlFixupHandler Apache::PerlVINC > > > > > > > > But as soon as I put these 4 lines, apache doesn't run anymore. > > > > An strace at start-up shows at the end : > > > > > > ..some stuff was here... > > > > > > > > It seems not to be happy not to found DESTROY.al, but after that i'm > > > > lost. > > > > What am I doing wrong ? How can I correct ? Is there another > > > > possibility to achieve the same goal ? > > > > (besides running different copies of Apache binded on different ports) > > > > > > > > If that's make a difference i'm also using Apache::StatINC > > > > > > > > Thanks in advance for your time and your answers. > > > > > > > > PS: modperl just rocks, kudos to everyone ! > > > > > > > > -- > > > > Patrick. > > > > Because if life has a meaning, we should already know it. > > > > > > > > -- > > Dave Moore > > Web Application Developer > > mailto:[EMAIL PROTECTED] > > > > ePALS Classroom Exchange > > http://www.epals.com/ > > Connecting more than 1.9 million students and teachers in 182 countries! > > -- > Patrick. > Because if life has a meaning, we should already know it. > _ Stas Bekman JAm_pH -- Just Another mod_perl Hacker http://stason.org/ mod_perl Guide http://perl.apache.org/guide mailto:[EMAIL PROTECTED] http://perl.org http://stason.org/TULARC http://singlesheaven.com http://perlmonth.com http://sourcegarden.org
Re: Apache::PerlVINC makes Apache segfault
[Cc to Stas as the example in the guide is wrong, and Dave explains the correct way] On Mon, Jul 31, 2000 at 03:42:18PM -0400, Dave Moore took time to write: > > duh...now that i've had some more coffee...the line: > > PerlVersionINC On > > must come before the PerlINC statement. PerlINC wont store that path > unless PerlVersionINC is On. Ok, that corrected my problem, thanks a lot Dave. > dave > On Mon, 31 Jul 2000, Dave Moore wrote: > > > you arent doing anything wrong. you probably just need to upgrade to the > > latest version of Apache::ExtUtils. this is not the same ExtUtils that > > comes with mod_perl 1.24. you will have to get it from the latest cvs > > snapshot of mod_perl. you will also have to remake/install PerlVINC after > > you install ExtUtils. see if that helps. > > > > On Sat, 29 Jul 2000, Patrick wrote: > > > > > Hi all, > > > > > > (debian potato) > > > apache-ssl : 1.3.9.13-2 > > > modperl : 1.21.2309-1 > > > perl : 5.005 > > > Apache::PerlVINC : 0.01 compiled by myself > > > > > > As recommended in the guide, i'm trying to use Apache::PerlVINC since > > > I have 3 virtualhosts, and the same sets of modules for all three (same >namespace), in > > > three separate directories (one production, two developpments). > > > > > > So I have in httpd.conf > > > > > > PerlModule Apache::PerlVINC > > > PerlINC /opt/anciens/membres > > > PerlVersionINC On > > > PerlFixupHandler Apache::PerlVINC > > > > > > But as soon as I put these 4 lines, apache doesn't run anymore. > > > An strace at start-up shows at the end : > > > > ..some stuff was here... > > > > > > It seems not to be happy not to found DESTROY.al, but after that i'm > > > lost. > > > What am I doing wrong ? How can I correct ? Is there another > > > possibility to achieve the same goal ? > > > (besides running different copies of Apache binded on different ports) > > > > > > If that's make a difference i'm also using Apache::StatINC > > > > > > Thanks in advance for your time and your answers. > > > > > > PS: modperl just rocks, kudos to everyone ! > > > > > > -- > > > Patrick. > > > Because if life has a meaning, we should already know it. > > > > > -- > Dave Moore > Web Application Developer > mailto:[EMAIL PROTECTED] > > ePALS Classroom Exchange > http://www.epals.com/ > Connecting more than 1.9 million students and teachers in 182 countries! -- Patrick. Because if life has a meaning, we should already know it. PGP signature
Re: Apache::ASP Response Redirect question
Hi there, On Sun, 6 Aug 2000, Rod Butcher wrote: > Can anybody please tell me whether the following internal redirect > causes the new URL to be sent back to the browser which then asks for > foo.htm to be served up, or does Apache simply serve up foo.htm > automatically ? I'll field this one because Josh is busy going to Sweden this weekend. > The comments in ASP.PM are very cryptic. :) But the documentation isn't! Have a look in the README. 73, Ged.
Apache::ASP Response Redirect question
Can anybody please tell me whether the following internal redirect causes the new URL to be sent back to the browser which then asks for foo.htm to be served up, or does Apache simply serve up foo.htm automatically ? The comments in ASP.PM are very cryptic. $Response->Redirect("foo.htm") Or is there a better (more efficient) way to do this ? Thanks Rod
fake browser
Hello, I don't know where to go with this question, may be somebody can help here, I have written a small program to simulate login to a site, but the site is trying to find out if the browser accessing it accepts cookies or not, and I wanted to know how to fake this, i.e. how to tell the program that I am a browser who is accepting cookies, I am using LWP::UserAgent to do the simulation, and I already told the site I am logging to that I am mozilla/4.0, here is a snippet of the code require LWP::UserAgent; $ua = new LWP::UserAgent; $ua->agent('Mozilla/4.0'); $request = new HTTP::Request GET=> 'http://www.namesforall.com/mail/login.cgi?user=me&password=mine'; $response = $ua->request($request); Issam
Hi! anyone there???
Hi, I am jitesh. Recently joined the list. Would like to say hello to all out there. jitesh
Re: ignore header_only()?
On Fri, 4 Aug 2000, Ken Fox wrote: > > I was using $request->sent_header and found out that it's > > not terribly useful if PerlSendHeader is off -- sent_header > > always returns 1. I changed mod_perl_sent_header so that > > it returns 0, 1 or 2: > > > > 0 - headers have not been sent (PerlSendHeader on) > > 1 - headers have not been sent (PerlSendHeader off) > > 2 - headers have already been sent I do that sort of thing for AxKit, overriding the Apache class and re-blessing $r, and implementing a safer send_http_header() that remembers if the headers have already been sent. -- Fastnet Software Ltd. High Performance Web Specialists Providing mod_perl, XML, Sybase and Oracle solutions Email for training and consultancy availability. http://sergeant.org | AxKit: http://axkit.org