httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dietz, Phil E." <PEDi...@West.com>
Subject RE: Module initialization and per-directory config directives
Date Fri, 14 May 1999 17:29:24 GMT
I also recommend a post_sent hook, so people can write modules that append
to a sent web document like footers, geocities popups, etc.

Right now I have to hack in an ap_rputs() inside of
ap_finalize_request_protocol().

	-----Original Message-----
	From:	Dean Gaudet [SMTP:dgaudet@arctic.org]
	Sent:	Friday, May 14, 1999 12:04 PM
	To:	new-httpd@apache.org
	Subject:	Re: Module initialization and per-directory config
directives

	The init() phase should be renamed post_config, and there should be
a
	pre_config phase added.

	That satisifies this right? 

	Dean

	On Fri, 14 May 1999, Zeev Suraski wrote:

	> 
	> I've sent this message two weeks ago but it never showed up for
some
	> reason, so this is a resend.
	> 
	> ---
	> 
	> One of the problems the PHP 3.0 Apache module had, was that
httpd.conf
	> directives were being parsed before module startups.  Since PHP
uses
	> various data structures to store values it reads from Apache
directives
	> (among other sources), and since these data structures weren't
being
	> initialized before Apache was calling the PHP's callback
functions, we had
	> to change the callbacks so that they always call PHP's startup
function
	> before going on.  Of course, we've put a flag inside that function
so that
	> it won't actually initialize more than once, but still, each .conf
or
	> .htaccess directive parsing resulted in an additional function
call, and
	> that function call had to be written on the top of every handler. 
	> 
	> While cleaning mod_php3.c for PHP 4.0, I was wondering on whether
this
	> behavior can be changed, or fixed in some way.  Is there no way to
ensure
	> that the module's startup is run before its callbacks are called
with
	> directive information? 
	> 
	> I realize that there's a good chance you can't simply move the
module
	> startups to be called before the configuration parsing (for
various
	> reasons), but if you can, or alternately, can provide an
additional module
	> initialzation function that's guarenteed to be called before the
	> configuration parsing, it would make callbacks look cleaner and be
more
	> efficient...
	> 
	> Comments?
	> 
	> Zeev
	> 
	> -- 
	> -----------------------------------------------------
	> Zeev Suraski <zeev@zend.com>
	> For a PGP public key, finger bourbon@netvision.net.il
	> 
	> 
	> 

Mime
View raw message