On Fri, 9 Mar 2001, julie wang wrote:
> HI!
>
> I'm new to Modperl. I been programming as a perl programmer (not the best,
> but I'm trying to improve) and been told to try and code using mod_perl. I
> got ORA's book on Apache Modules and was reading about how to code using
> mod_perl. Am I right to assume mod_perl is more Apache conf. than anything
> else? (if using Apache::Registry) I been coding perl using the -w flag as
> well as "use strict". I shouldn't need to alter how I code Perl, right?
>
> Is there anyway to test if the server is running in mod_perl or not? I know
> this is one of the FAQ questions, but I didn't really understand. I am
> using exit(0); and exit; to terminate my perl scripts. What should I
> replace that with if it is advise not to do so when using mod_perl?? The
> FAQ suggests using "goto" kind of statement. I rather not use that. What
> other alternatives do I have? Thanks!
Before the rain of questions comes in, please parse this pseudo-perl code:
package Apache::AnyQuestions;
use Apache::Constants;
use constant SEEK_ANSWER => SEEK_CUR;
sub handler{
while (shift @questions){
open RTFM, 'http://perl.apache.org/guide/' or die $!;
while (still_not_found($_);)
seek RTFM, 0, SEEK_ANSWER;
read RTFM, $mind, 2**16;
sleep 3600;
}
close RTFM;
}
return Apache::Constants::DECLINED;
}
1;
thanks :)
_____________________________________________________________________
Stas Bekman JAm_pH -- Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide http://perl.apache.org/guide
mailto:[EMAIL PROTECTED] http://apachetoday.com http://logilune.com/
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/