You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Jason Kwon <jk...@quinstreet.com> on 2005/09/08 23:05:23 UTC

Multiple Webapps and the TLDs

Say I have multiple webapps. 
Currently, I am deploying each webapp with their own copies of the
struts TLDs.
Is there any way I can deploy each webapp and deploy only a single set
of struts TLDs?  

Re: Multiple Webapps and the TLDs

Posted by Wendy Smoak <ja...@wendysmoak.com>.
From: "Michael Jouravlev" <jm...@gmail.com>

> Ok, I have Struts 1.2.7 distro, which contains META-INF/tlds directory
> with the following tld files:
...
> *1.1.tld files have older uri in them referring jakarta.struts
> (interesting why they have higher version number?).

What do you mean by higher version number?   A quick check shows they are
all Struts 1.2 tlds (look at the <tlibversion> in them).  And that the pairs
match exactly except for the URIs.  The *1.1.tld files are probably there
for backwards compatibility, though I can't quite come up with a good
explanation.

> What about EL tags? Will they be included in distro? With JSP 2.4 most
> users will fall back to standard Struts tags, but I use Struts-EL and
> I would like it to be in the distro as well.

For 1.2, Struts-EL is in the 'contrib' directory.  If there were to be a
Struts 1.2.8 release, there's no reason to think EL would be excluded.

If you're asking about 1.3, the release notes show that Struts-EL is
intended to be part of "Struts Classic 1.3.0".
http://wiki.apache.org/struts/StrutsClassicRelease130

I don't think you have to worry about Struts-EL disappearing. :)

-- 
Wendy


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Multiple Webapps and the TLDs

Posted by Michael Jouravlev <jm...@gmail.com>.
On 9/8/05, Wendy Smoak <ja...@wendysmoak.com> wrote:
> From: "Jason Kwon" <jk...@quinstreet.com>
> 
> > Say I have multiple webapps.
> > Currently, I am deploying each webapp with their own copies of the
> > struts TLDs.
> > Is there any way I can deploy each webapp and deploy only a single set
> > of struts TLDs?
> 
> There is a way you can deploy *none* of the tlds. :)  Assuming you're on a
> Servlet 2.3 or better container, and that by "deploying" you mean you're
> putting the tlds under WEB-INF and configuring them in web.xml, all you have
> to do is start using the right URI in your <@taglib> tags, and the tlds
> which are already in (for example) struts.jar will be automatically used.
> 
> Example:
>    <%@ taglib uri="http://struts.apache.org/tags-html-el" prefix="html" %>
> 
> If you're using the non-el version of the tags, the URI will be different--
> look in the tld itself for the
> <uri>http://struts.apache.org/tags-html</uri>, and use that in your <%@
> taglib> tag.
> 
> Then delete the .tld files from wherever you had them, and delete the
> <taglib> tags from web.xml.

Ok, I have Struts 1.2.7 distro, which contains META-INF/tlds directory
with the following tld files:

struts-bean-1.1.tld
struts-bean.tld
struts-html-1.1.tld
struts-html.tld
struts-logic-1.1.tld
struts-logic.tld
struts-nested-1.1.tld
struts-nested.tld
struts-tiles-1.1.tld
struts-tiles.tld

*1.1.tld files have older uri in them referring jakarta.struts
(interesting why they have higher version number?).

What about EL tags? Will they be included in distro? With JSP 2.4 most
users will fall back to standard Struts tags, but I use Struts-EL and
I would like it to be in the distro as well.

Michael.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Multiple Webapps and the TLDs

Posted by Wendy Smoak <ja...@wendysmoak.com>.
From: "Jason Kwon" <jk...@quinstreet.com>

> Say I have multiple webapps.
> Currently, I am deploying each webapp with their own copies of the
> struts TLDs.
> Is there any way I can deploy each webapp and deploy only a single set
> of struts TLDs?

There is a way you can deploy *none* of the tlds. :)  Assuming you're on a
Servlet 2.3 or better container, and that by "deploying" you mean you're
putting the tlds under WEB-INF and configuring them in web.xml, all you have
to do is start using the right URI in your <@taglib> tags, and the tlds
which are already in (for example) struts.jar will be automatically used.

Example:
   <%@ taglib uri="http://struts.apache.org/tags-html-el" prefix="html" %>

If you're using the non-el version of the tags, the URI will be different--
look in the tld itself for the
<uri>http://struts.apache.org/tags-html</uri>, and use that in your <%@
taglib> tag.

Then delete the .tld files from wherever you had them, and delete the
<taglib> tags from web.xml.

-- 
Wendy Smoak


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org