Charlie,

I want to make sure I'm understanding your suggestion. I would do something like this 
in server.xml:

<Host name="www.siteA.com">
        <!-- Common Context - These files are shared between all domains -->
        <Context path="" docBase="common" debug="0" reloadable="true"/>
         
        <!-- Local Context  - These files are specific to this domain -->
        <Context path="/local" docBase="siteA" debug="0" reloadable="true"/>
</Host>

<Host name="www.siteB.com">
        <!-- Common Context - These files are shared between all domains -->
        <Context path="" docBase="common" debug="0" reloadable="true"/>
         
        <!-- Local Context  - These files are specific to this domain -->
        <Context path="/local" docBase="siteB" debug="0" reloadable="true"/>
</Host>

Is this what you meant? Is there anyway to have Tomcat automaticaly look for a file in 
the Common Context if it doesn't find it in the Local Context?

Thanks,
Steve

> -----Original Message-----
> From: Cox, Charlie [mailto:[EMAIL PROTECTED]]
> Sent: Monday, November 18, 2002 8:31 AM
> To: 'Tomcat Users List'
> Subject: RE: Possible to subclass a web application?
> 
> 
> Put all yout common code in one context, make a context 
> available for it in
> each virtual host. Then create a context-specific 
> directory(named the same
> in all hosts) that contains header.jsp,etc that are specific 
> to each host.
> 
> Charlie
> 
> > -----Original Message-----
> > From: Turoff, Steve [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, November 15, 2002 4:52 PM
> > To: Tomcat Users List
> > Subject: RE: Possible to subclass a web application?
> > 
> > 
> > Cees,
> > 
> > Thanks for the advice. I thought about doing it your way, 
> > however there will actually be 4 or 5 sites, some of which 
> > will override more than just header.jsp and footer.jsp. I 
> > think this will lead to a maintenance nightmare down the 
> > road. Plus, I like the idea of being able to add new content 
> > to siteB, which wouldn't exist in siteA. 
> > 
> > I worked for a company several years ago and we did this 
> > using Dynamo, which is why I thought Tomcat might be able to 
> > handle it, too. Unfortunately, I wasn't privy to the configuration.
> > 
> > Steve
> > 
> > > -----Original Message-----
> > > From: Cees van de Griend [mailto:[EMAIL PROTECTED]]
> > > Sent: Friday, November 15, 2002 3:48 PM
> > > To: Tomcat Users List; Turoff, Steve
> > > Subject: Re: Possible to subclass a web application?
> > > 
> > > 
> > > On Friday 15 November 2002 22:17, Turoff, Steve wrote:
> > > > I currently have a Tomcat (v 3.2.3) - Apache (v 1.3.19) - 
> > > Red-Hat web site,
> > > > www.siteA.com, that consists of several hundred jsp pages 
> > > and several
> > > > servlets. I want to create a second web site, 
> > > www.siteB.com, that uses the
> > > > same content, but has a different look-and-feel. 
> > > 
> > > Use <alias> inside your server.xml <host> part to point the 
> > > two domains to the
> > > same webapp.
> > > Use request.getServerName() in your JSP files to point to a 
> > > different CSS 
> > > file.
> > > 
> > > Regards,
> > > Cees.
> > > 
> > > 
> > 
> > --
> > To unsubscribe, e-mail:   
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> 
> --
> To unsubscribe, e-mail:   
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to