Apache-ASP
view release on metacpan or search on metacpan
site/faq.html view on Meta::CPAN
</tr>
<tr>
<td valign=top >
<font face="lucida console" size=-1>
<a href=#How%20can%20I%20us50054dc6>How can I use $Session to store a $dbh database handle ?</a>
</font>
</td>
<td valign=top >
<font face="lucida console" size=-1>
<a href=#What%20is%20the%20bd2800a9>What is the state of Apache::ASP? Can I publish a web site on it?</a>
</font>
</td>
</tr>
<tr>
<td valign=top >
<font face="lucida console" size=-1>
</font>
</td>
<td> </td>
</tr>
</table>
<hr size=1>
<p>
<p>
<a name=Installation></a>
<font face=verdana><font class=title size=+0 color=#555555><b>Installation</b></font>
</font>
<p>
<a name=Examples%20donf48a0968></a>
<font face=verdana><font class=title size=-1 color=#555555><b>Examples don't work, I see the ASP script in the browser?</b></font>
<font face="courier new" size=3><pre>
</pre></font>This is most likely that Apache is not configured to execute
the Apache::ASP scripts properly. Check the <a href=install.html><font size=-1 face=verdana><b>INSTALL</b></font></a> QuickStart
section for more info on how to quickly set up Apache to
execute your ASP scripts.</font>
<p>
<a name=Apache%20Expat3f8589db></a>
<font face=verdana><font class=title size=-1 color=#555555><b>Apache Expat vs. XML perl parsing causing segfaults, what do I do?</b></font>
<font face="courier new" size=3><pre>
</pre></font>Make sure to compile apache with expat disabled. The
./make_httpd/build_httpds.sh in the distribution will do
this for you, with the --disable-rule=EXPAT in particular:
<font face="courier new" size=3><pre>
cd ../$APACHE
echo "Building apache =============================="
./configure \
--prefix=/usr/local/apache \
--activate-module=src/modules/perl/libperl.a \
--enable-module=ssl \
--enable-module=proxy \
--enable-module=so \
--disable-rule=EXPAT
^^^^^
</pre></font>keywords: segmentation fault, segfault seg fault</font>
<p>
<a name=Why%20do%20varia68e97184></a>
<font face=verdana><font class=title size=-1 color=#555555><b>Why do variables retain their values between requests?</b></font>
<font face="courier new" size=3><pre>
</pre></font>Unless scoped by my() or local(), perl variables in <a href=http://perl.apache.org><font size=-1 face=verdana><b>mod_perl</b></font></a>
are treated as globals, and values set may persist from one
request to another. This can be seen in as simple a script
as this:
<font face="courier new" size=3><pre>
<HTML><BODY>
$counter++;
$Response->Write("<BR>Counter: $counter");
</BODY></HTML>
</pre></font>The value for $counter++ will remain between requests.
Generally use of globals in this way is a BAD IDEA,
and you can spare yourself many headaches if do
"use strict" perl programming which forces you to
explicity declare globals like:
<font face="courier new" size=3><pre>
use vars qw($counter);
</pre></font>You can make all your Apache::ASP scripts strict by
default by setting:
<font face="courier new" size=3><pre>
PerlSetVar UseStrict 1
</pre></font>
<p>
<a name=Apache%20errorf0bcd572></a>
<font face=verdana><font class=title size=-1 color=#555555><b>Apache errors on the PerlHandler or PerlModule directives ?</b></font>
<font face="courier new" size=3><pre>
</pre></font>You get an error message like this:
<font face="courier new" size=3><pre>
Invalid command 'PerlModule', perhaps mis-spelled or defined by a
module not included in the server configuration.
</pre></font>You do not have <a href=http://perl.apache.org><font size=-1 face=verdana><b>mod_perl</b></font></a> correctly installed for Apache. The PerlHandler
and PerlModule directives in Apache *.conf files are extensions enabled by mod_perl
and will not work if mod_perl is not correctly installed.
<font face="courier new" size=3><pre>
</pre></font>Common user errors are not doing a 'make install' for mod_perl, which
installs the perl side of mod_perl, and not starting the right httpd
after building it. The latter often occurs when you have an old apache
server without mod_perl, and you have built a new one without copying
over to its proper location.
<font face="courier new" size=3><pre>
</pre></font>To get mod_perl, go to <a href=http://perl.apache.org>http://perl.apache.org</a></font>
<p>
<a name=Error%3A%20no%20reb1d13fcf></a>
<font face=verdana><font class=title size=-1 color=#555555><b>Error: no request object (Apache=SCALAR(0x???????):)</b></font>
<font face="courier new" size=3><pre>
</pre></font>Your Apache + <a href=http://perl.apache.org><font size=-1 face=verdana><b>mod_perl</b></font></a> build is not working properly,
and is likely a RedHat Linux RPM DSO build. Make sure
you statically build your Apache + mod_perl httpd,
( run in 0.925 second using v1.01-cache-2.11-cpan-acf6aa7dc9e )