Frank if you dynamicaly set the root name in the application page as follows:
<cfset root="root1">
for the first site
or
<cfset root="root2">
for the second site.

you can then use the tag in this format
<cfinclude template="\#root#\subdir\test.cfm"> and it will work on both sites using 
the same path.

thanks
 Frederic


"Newman, Frank (OD)" wrote:

> Thanks for your quick reply Sandra, however, I was hoping to have the sites
> both "look" like they are at the root so that both www.server1.com/index.cfm
> and www.server2.com/index.cfm would be different pages on different sites
> sharing the same box.  The cfinclude tag would work the way its supposed to
> in each virtual site.
>
> You did give me a solution, but not the one I was looking for...Appreciate
> the help...Frank
>
> -----Original Message-----
> From: Sandra Clark [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, January 04, 2001 10:39 AM
> To: CF-Server
> Subject: RE: Multiple sites, one box and CF Server
>
> Define two mappings in CFAdmin
> \root1 - d:\root1
> \root2 - d:\root2
>
> Then use these mappings in the program.
>
> <cfinclude template="\root1\subdir\test.cfm"> should then work.
>
> When you have the \subdir\test.cfm in there, the webserver assumes that it
> is the actual root.  Set up the mappings in CFAdmin to save yourself
> headaches.
>
> -----Original Message-----
> From: Newman, Frank (OD) [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, January 04, 2001 7:26 AM
> To: CF-Server
> Subject: Multiple sites, one box and CF Server
>
> I am running CF server on a single NT 4.0 box hosting multiple sites.  Here
> is my configuration:
>
> Site A : IP 10.0.0.1 with DNS www.server1.com and root d:\root1
> Site B:  IP 10.0.0.2 with DNS www.server2.com and root d:\root2
>
> my problem is that when I use the <cfinclude> tag in d:\root2 with an
> absolute path, it tries to include files from d:\root1.  For example, when
> is use <cfinclude template="/subdir/test.cfm"> in d:\root2, CF server wants
> to grab d:\root1\subdir\test1.cfm when it should be grabbing
> d:\root2\subdir\test1.cfm.
>
> The CFADMIN program gives you a way to set your root but it looks like you
> can only have one.  Anyone have a solution to this problem other than using
> relative references in your cfinclude tag?
>
> Thanks in advance...
>
> Frank Newman
> Web Developer
> National Institutes of Health
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm
------------------------------------------------------------------------------
To unsubscribe, send a message to [EMAIL PROTECTED] with 
'unsubscribe' in the body or visit the list page at www.houseoffusion.com

Reply via email to