httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nathan Schrenk <>
Subject I think I've tracked down my SSI problem
Date Sat, 17 Feb 1996 23:38:12 GMT

I went through mod_include.c today looking for why the SSI directive 
<!--#echo var="QUERY_STRING_UNESCAPED" --> doesn't work under Apache 
1.0.2 (and other previous versions, I'm sure.)  It seems that this must 
have been broken for a long time, as I don't remember seeing any 
significant changes to mod_include.c for quite a while.

Anyway, as far as I can tell, the environment that an echo variable acts 
upon is created by add_common_vars() and add_include_vars() which are 
called in send_parsed_file().  add_include_vars() does not add 
For some reason, QUERY_STRING and QUERY_STRING_UNESCAPED _are_ added in 
include_cmd_child, but this doesn't make these variables available to the 
echo directive.  

The NCSA SSI doc at
states "A number of variables are made available to parsed documents. In 
addition to the CGI variable set, the following variables are made 
available:" ...

That indicates that the echo directive is required to have all of the CGI
variables available to it.  What do you think the best solution to the
problem is?  Should I just duplicate the functionality of add_cgi_vars()
in add_include_vars()?  Or perhaps moving add_cgi_vars() out into
util_script.c and calling add_cgi_vars() from mod_include.c is a better

If I don't hear any better suggestions or criticism of the second
approach, I'm going to submit a patch using that method to fix this
problem.  I'm suprised no one has run into this problem before.


Nathan Schrenk
Neoglyphics Media Corp.                    

View raw message