This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Including XHTML DTD in output
- To: XSL-List at lists dot mulberrytech dot com
- Subject: [xsl] Including XHTML DTD in output
- From: Nathan Shaw <n8_shaw at yahoo dot com>
- Date: Thu, 2 Aug 2001 05:37:21 -0700 (PDT)
- Reply-To: xsl-list at lists dot mulberrytech dot com
Hi all,
How do I include an XHTML DTD in my output?
I have tried adding it to my XSLT of course, to no
avail, as a DOCTYPE declaration is not allowed.
I need to have the DOCTYPE declaration in the
resulting output as IE5.5 & Netscape 6 behave
differently if the DOCTYPE is not included (they go
into quirks mode).
It would also be nice to be able to strip out the XML
tag that results from the transformation so that older
browsers do not choke on it.
Any ideas? Here is the XSL:
<?xml version="1.0"?>
<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:output method="xml" />
<xsl:strip-space elements="*" />
<xsl:template match="/">
<!--<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0
Transitional//EN"
"DTD/xhtml1-transitional.dtd">-->
<html>
<head>
<link rel="stylesheet" href="styles.css"
type="text/css" />
<title>OBPR Enterprise - <xsl:value-of
select="WebContent/Content/Header/@Title" /></title>
</head>
<body text="#000000" bgcolor="#ffffff" alink="#cc0000"
link="#3333ff"
vlink="#003399">
<div align="center">
<table width="500" border="0" cellspacing="0"
cellpadding="0"
align="center">
<tr>
<td align="left" valign="top"><a
href="/index.html"><img src="2bpre.gif"
height="90" width="300" alt="Biological and Physical
Research Enterprise"
border="0" /></a><a href="http://www.nasa.gov/"><img
src="nlogo.gif"
align="bottom" height="48" width="59" border="0"
alt="NASA Logo" /></a></td>
</tr>
</table>
<br />
<xsl:apply-templates />
<!-- Begin lower boilerplate -->
<table width="500" border="0" cellspacing="0"
cellpadding="0"
align="center">
<tr>
<td class="footer" align="right"><hr size="1" />NASA
Headquarters
Responsible Official: Code U<br />Curator: <a
href="/contact.html">Office of
Biological
and Physical Research</a></td>
</tr>
</table>
<!-- End lower boilerplate -->
</div>
</body>
</html>
</xsl:template>
TIA--Nate
=====
----------------------------
Nathan Shaw
Web Applications Developer
iaffect
http://www.iaffectonline.com
http://www.iaffectTV.com
----------------------------
__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list