Yes, I have already implemented choice 1.  Good points David.

Dave






From: "Karr, David" <[EMAIL PROTECTED]>
Reply-To: "Struts Developers List" <[EMAIL PROTECTED]>
To: "Struts Developers List" <[EMAIL PROTECTED]>
Subject: RE: [VOTE] How to implement XHMTL support
Date: Tue, 12 Nov 2002 16:14:10 -0800

Just so I understand, you're experimenting with making tags generated
from a jsp:include be xhtml-compliant even if the original page wasn't
specified as being xhtml-compliant? It seems to me that XHTML
compliance is an attribute of an "html" element and its nested elements
(including the associated DOCTYPE), and not an attribute of an HTTP
request. This would mean that a page that was jsp:included would
generate different output depending on what page included it.

I'd say that choice 1 (only affecting the elements nested in the "html"
element), which I assume is what you've already done, is preferable to
choice 2 (runtime determination).

> -----Original Message-----
> From: David Graham [mailto:dgraham1980@;hotmail.com]
>
> I've updated that html taglib tags to output xhtml when they
> are nested in a
> <html:html xhtml="true"> tag. This was very simple to do and
> resulted in
> minor code changes. Users have suggested this approach:
>
> 1. Add Globals.XHTML_KEY which is a boolean request scoped attribute
> 2. html tags check for that request attribute being true and output
> accordingly.
> 3. The html:html tag sets this request attribute when it's
> xhtml attribute
> is true.
>
> The second approach allows the tags to output xhtml without
> relying on the
> <html:html> tag. This allows people to construct pages with
> jsp includes.
> The first approach is logically clearer (to me) and you can
> use tiles to
> modularly construct the pages like includes. Approach 2 may
> be confusing
> because you would have to remember all the places you may
> have set that
> request attribute.
>
> So, do we go with 1, 2 or both?

--
To unsubscribe, e-mail: <mailto:struts-dev-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-dev-help@;jakarta.apache.org>

_________________________________________________________________
The new MSN 8: advanced junk mail protection and 2 months FREE* http://join.msn.com/?page=features/junkmail


--
To unsubscribe, e-mail: <mailto:struts-dev-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-dev-help@;jakarta.apache.org>

Reply via email to