Len45
asked on
Apache Alias and Directory
Working with:
Fedora Core 3
Apache 2.0.52
BlueDragon JX 6.2.1 (CF MX)
I have created a alias in httpd.conf to /forum
Inside /form is subdirectory installation
When I go to the actual URL (where it really is) everything works the way it is supposed to. That is when I browse into the installation directory, the Application.cfm file in /forum is referenced properly. If I am on one of the other domains where /forum should be available, CF does not "find" Application.cfm.
I have used Alias and Directory and tried everything I could think of in the envelope
Alias /forum "/xxx/controlpanel/_module s/forum/"
<Directory /xxx/controlpanel/_modules /board >
Options Indexes FollowSymLinks MultiViews ExecCGI Includes
AllowOverride None
Order allow,deny
Allow from all
AcceptPathInfo On
Satisfy Any
</Directory>
Fedora Core 3
Apache 2.0.52
BlueDragon JX 6.2.1 (CF MX)
I have created a alias in httpd.conf to /forum
Inside /form is subdirectory installation
When I go to the actual URL (where it really is) everything works the way it is supposed to. That is when I browse into the installation directory, the Application.cfm file in /forum is referenced properly. If I am on one of the other domains where /forum should be available, CF does not "find" Application.cfm.
I have used Alias and Directory and tried everything I could think of in the envelope
Alias /forum "/xxx/controlpanel/_module
<Directory /xxx/controlpanel/_modules
Options Indexes FollowSymLinks MultiViews ExecCGI Includes
AllowOverride None
Order allow,deny
Allow from all
AcceptPathInfo On
Satisfy Any
</Directory>
ASKER
Tried that, should have worked, but didn't
ASKER
The way I understand it mapping works for cfinclude, cfmodule and cfs's ??
yes it does. To be honest, I am a little confused by the structure in your question.
Can you identify your folder hierarchy. Rereading it, it sounds like perhaps your application.cfm file isn't in a folder above your current folder, but in a sibling one...
ASKER
/xxx/xxx/_modules/forum/in stallation /
Application.cfm is in forum
Application.cfm is in forum
ASKER
laid it out a bit differently in my original question, sorry to confuse. But Application.cfm (LINUX need "A" not "a", but you know that) is in the directory "above" installation and is accessed when I go to the web space where it actually resides
so is I go to
http://mydomain.com/controlpanel/_modules/board/installation/index.cfm -- all is well with the world
I have used Alias and Directory in the httpd.conf to "map" /forum to that directory and if I go to another domain on my server
http://AnotherDomain.com/forum/installation/index.cfm -- it is not "seeing" Application.cfm which would now be in the forum directory.
so is I go to
http://mydomain.com/controlpanel/_modules/board/installation/index.cfm -- all is well with the world
I have used Alias and Directory in the httpd.conf to "map" /forum to that directory and if I go to another domain on my server
http://AnotherDomain.com/forum/installation/index.cfm -- it is not "seeing" Application.cfm which would now be in the forum directory.
ASKER
I am wondering if I have my <directory> set up right? Anyone have suggestions?
Application.cfm is found by an upward search of physical folders, not related to the URL or mappings, right? So if your template launched is in this hypothetical directory /A/B/C/D/E/index.cfm your application.cfm needs to be in A,B,C,D or E.
So in this example,
http://AnotherDomain.com/forum/installation/index.cfm
Directory:
xxx/controlpanel/_modules/
It seems like it would work if Application.cfm is located in your forum directory.
In this example, installation, is inside of board, not inside of forum, so I would think it would not find it..
http://mydomain.com/controlpanel/_modules/board/installation/index.cfm
Directory:
/xxx/controlpanel/_modules
What if you place the Application.cfm inside of _modules ? That seems to be shared by both?
Do you only have one Application.cfm file, or are you attempting to launch different ones depending on something. If only one, place it in the web root ?
ASKER
gdemaria -- thanks for sticking with me on this one, it is really weird
Base on the Alias that I have set up in the apache conf file /forum and /board are the same actual directory on the server, that what is so weird.
CF usually does not care about names... it just goes up the "tree" till it finds a Application.cfm file -- maybe names matter in a case like this?
When I am in installation and pull up index.cfm it is exactly the same file, if just does not reference Application.cfm in the parent directory when I am in forum -- this has got to be an apache deal with the Alias and Directory "requests"
Base on the Alias that I have set up in the apache conf file /forum and /board are the same actual directory on the server, that what is so weird.
CF usually does not care about names... it just goes up the "tree" till it finds a Application.cfm file -- maybe names matter in a case like this?
When I am in installation and pull up index.cfm it is exactly the same file, if just does not reference Application.cfm in the parent directory when I am in forum -- this has got to be an apache deal with the Alias and Directory "requests"
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
what is really weird is that if I do a <cfinclude template="../Application.c fm"> it works. I will play a bit with your suggestion -- especially the getTemplatePath()
Thanks
Thanks
ASKER
gdemaria
Your code helped me track down a problem with how I had set up the Alias directive in the apache.conf file, did not have anything to do with CF (or in my case BlueDragon), thanks for the help... don't spend all those points in one place, eh? :-)
Your code helped me track down a problem with how I had set up the Alias directive in the apache.conf file, did not have anything to do with CF (or in my case BlueDragon), thanks for the help... don't spend all those points in one place, eh? :-)
try adding the folder as a mapping in the coldfusion administrator