This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: <br/> tags, xhtml output, and netscape
- From: Wendell Piez <wapiez at mulberrytech dot com>
- To: xsl-list at lists dot mulberrytech dot com
- Date: Fri, 22 Mar 2002 13:36:35 -0500
- Subject: Re: [xsl] <br/> tags, xhtml output, and netscape
- Reply-to: xsl-list at lists dot mulberrytech dot com
Brook,
The usual trick is to put a dummy attribute in there, e.g.
<br class="br"/>
to force the space. Netscape is okay with that.
FWIW, in your stylesheet saying <br /> is the same as saying <br/>: the
space doesn't make any difference. You're specifying an element node for
your result tree, not a tag.
This used to be a FAQ, but we haven't seen it in a while.
Cheers,
Wendell
At 12:31 PM 3/22/2002, you wrote:
>Hello all,
>
>I've got <br_/>tags (the underscore represents a space) in my xsl and am
>outputing as xhtml with:
>
><xsl:output method="xml" doctype-system="DTD/xhtml1-transitional.dtd"
>doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" version="1.0"
>encoding="ISO-8859-1" indent="no"/>
>
> in the header.
>
>The html produced is great but, the break tags are outputed without the
>space i.e. <br/> instead of <br_/>. Netscape (4.x) doesn't deal with this
>very well, as expected. Changing the output method to "html" sorts the
>problem out, but I'd prefer to have valid xhtml.
>
>So my predictable question (and probably oft-asked, though I did have a root
>though the archives) is , how can I output my break tag with a space with
>method="xml"?
======================================================================
Wendell Piez mailto:wapiez@mulberrytech.com
Mulberry Technologies, Inc. http://www.mulberrytech.com
17 West Jefferson Street Direct Phone: 301/315-9635
Suite 207 Phone: 301/315-9631
Rockville, MD 20850 Fax: 301/315-8285
----------------------------------------------------------------------
Mulberry Technologies: A Consultancy Specializing in SGML and XML
======================================================================
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list