You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Nalini Kumar Danda <dn...@cisco.com> on 2001/03/28 05:01:41 UTC

Include directive problem

Hi,

I have a problem with an application that is developed on top of apache.

I would like to have a configuration split in two different files,
though apache encourages to have it in a single file.

I have a requirement that I should be able to "Include
conf/somefile.txt"
in the main httpd.conf file and use the contents of "somefile.txt" as
though they appear in httpd.conf.

Example:

httpd.conf
----------

ServerRoot "/home/dnkumar/myproject4"
.
some directives...
.
Include conf/somefile.txt


somefile.txt
------------
<Mycontainer 10.1>
directive1      somevalue1
directive2      somevalue2
</Mycontainer>

<Mycontainer 10.2>
directive1      somevalue3
directive2      somevalue4
</Mycontainer>

We are currently using Apache alpha 1.3 version. The problem I have is,
the code does not recognize the "<Mycontainer 10.1>" at all. It does
not call the corresponding "set_" function. Ofcourse, it also does not
recognize "</Mycontainer>".  What happens is, it reads the directive1
& directive2 under "Mycontainer 10.1" but not "Mycontainer 10.2"
and anything that follows...
But If I change my code & configs to use "[Mycontainer 10.1]",
it works fine.

Is there a fix for this in the recent versions of apache or httpd ?
Does this happen to you too ? We know we have not touched
any of the apache code we have.  I would appreciate your feedback
at the earliest.

thanks,
Nalini Kumar.




Re: Include directive problem

Posted by "William A. Rowe, Jr." <ad...@rowe-clan.net>.
From: "Nalini Kumar Danda" <dn...@cisco.com>
Sent: Tuesday, March 27, 2001 9:01 PM


> Hi,
> 
> I have a problem with an application that is developed on top of apache.

So you told us earlier today [Subject: help please..].

This forum is for core server development, and discussions of complications.
What you are trying to do is outside of what the ApacheCore accepts in it's
directives, so it sounds like your script is rewritten on the way in before 
Apache parses it.

Please take your further questions to an appropriate forum, such as the
newsgroup comp.infosystems.www.servers.unix for help on configuration.