:: ASP FAQ ::
· Examples don't work, I see the ASP script in the browser?
This is most likely that Apache is not configured to execute the Apache::ASP scripts properly. Check the INSTALL QuickStart section for more info on how to quickly set up Apache to execute your ASP scripts.
· Apache Expat vs. XML perl parsing causing segfaults, what do I do?
^^^^^ keywords: segmentation fault, segfault seg fault
· Why do variables retain their values between requests?
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:
You can make all your
Apache::ASP scripts strict by default by setting:
· Apache errors on the PerlHandler or PerlModule directives ?
You do not have mod_perl 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. 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. To get mod_perl, go to http://perl.apache.org
· Error: no request object (Apache=SCALAR(0x???????):)
· I am getting a tie or MLDBM / state error message, what do I do?
Usually a will take care of the write access issue for initial testing purposes. Failing write access being the problem, try upgrading your version of Data::Dumper and MLDBM, which are the modules used to write the state files.
· How can I use $Session to store complex data structures.
In particular, stay away
from statements that that have more than one level of indirection on the left
side of an assignment like:
· How can I keep search engine spiders from killing the session manager?
<Perl>
package My::InitHandler;
sub handler {
# if not a Mozilla User
Agent, then disable sessions explicitly
return 200; # return OK
mod_perl status code 1; </Perl> This will configure your environment before Apache::ASP executes and sees the configuration settings. You can use the mod_perl API in this way to configure Apache::ASP at runtime. Note that the Session Manager is very robust on its own, and denial of service attacks of the types that spiders and other web bots normally execute are not likely to affect the Session Manager significantly.
· How can I use $Session to store a $dbh database handle ?
Database handles often have per process file handles open, which cannot be shared between requests, so though you have stored the $dbh data in $Session, all the other initializations are not relevant in another httpd process. All is not lost! Apache::DBI can be used to cache database connections on a per process basis, and will work for most cases.
· VBScript or JScript supported?
Instant ASP from Stryon (formerly Halcyon Software)
· How is database connectivity handled?
DBD::ODBC is often your ticket on Win32. On UNIX, commercial vendors like OpenLink Software (http://www.openlinksw.com/) provide the nuts and bolts for ODBC. Database connections can be cached per process with Apache::DBI.
· What is the best way to debug an ASP application ?
· How are file uploads handled?
· How do I access the ASP Objects in general?
This notation can be used from anywhere in perl, including routines registered with $Server->RegisterCleanup().
You use the normal
notation in your scripts, includes, and global.asa:
· Can I print() in ASP?
· Do I have access to ActiveX objects?
Support and Production
· How do I get things I want done?
· What is the state of Apache::ASP? Can I publish a web site on it?
|
|
|||
|
||||
|
Copyright
©
2003 All rights reserved
Created by Shubhankar Dey
(Click here to
get real font)