|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Namespaces
I am sorry that I did not include a link to the dtd. I would
have included it in the email, but it's kind of a big dtd, and
includes multiple files.
Anyway, the dtd is here:
http://davetotten.com/art501/
art501.dtd does have a default namespace defined, but I still do not
understand how I can access it's elements. Please forgive me for
my ignorance, but I still haven't seen any examples that explain
this to me.
I have since tried the following, as attributes to my <xsl:stylesheet> tag.
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:ce="http://www.elsevier.com/xml/common/dtd"
xmlns:sb="http://www.elsevier.com/common/struct-bib/dtd"
xmlns="http://www.elsevier.com/xml/ja/dtd">
and then to make it match the dtd completely (I think)
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:ce="'http://www.elsevier.com/xml/common/dtd'"
xmlns:sb="'http://www.elsevier.com/common/struct-bib/dtd'"
xmlns="'http://www.elsevier.com/xml/ja/dtd'">
Thanks, I appreciate the help.
Dave
On Mon, Jun 09, 2003 at 02:16:28PM -0400, David Totten wrote:
> Given the following xml,
>
> <?xml version="1.0" encoding="utf-8"?>
> <?xml-stylesheet href="elsevier-art5.xsl" type="text/xsl"?>
> <!DOCTYPE article PUBLIC "-//ES//DTD journal article DTD version
> 5.0.1//EN//XML" "art501/art501.dtd">
> <article docsubtype="fla" xml:lang="en">
> <item-info>
> <jid>CPLETT</jid>
> <ce:pii>S0009261403003269</ce:pii>
> <ce:copyright type="full-transfer" year="2003">Elsevier Science
> B.V.</ce:copyright>
> </item-info>
> <head>
> <ce:title>test</ce:title>
> <ce:author-group>
> <ce:author>
> <ce:given-name>Totten</ce:given-name>
> <ce:surname>David</ce:surname>
> </ce:author>
> </ce:author-group>
> </head>
> </article>
>
> using this xsl stylesheet:
>
> <?xml version="1.0" encoding="ISO-8859-1"?>
>
> <!DOCTYPE xsl:stylesheet [
> <!ENTITY xhtml-lat1
> "http://www.w3.org/TR/xhtml1/DTD/xhtml-lat1.ent">
> <!ENTITY xhtml-special
> "http://www.w3.org/TR/xhtml1/DTD/xhtml-special.ent">
> <!ENTITY xhtml-symbol
> "http://www.w3.org/TR/xhtml1/DTD/xhtml-symbol.ent">
> <!ENTITY nbsp " ">
> <!ENTITY copy "©">
> <!ENTITY quote """>
> <!ENTITY rdquo """>
> <!ENTITY ldquo """>
> <!ENTITY reg "®">
> ]>
>
> <xsl:stylesheet version="1.0"
> xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
> xmlns:ce="http://www.elsevier.com/xml/common/dtd"
> xmlns:sb="http://www.elsevier.com/common/struct-bib/dtd"
> xmlns="http://www.w3.org/TR/REC-html40">
>
> <xsl:output method="html" encoding="UTF8"/>
> <xsl:strip-space elements="*"/>
>
> <xsl:template match="/">
> <HTML>
> <HEAD>
> <META HTTP-EQUIV="Content-language" CONTENT="en-US"/>
> <META HTTP-EQUIV="Content-Type"
> CONTENT="text/html;" CHARSET="UTF-8"/>
> <TITLE>
> <xsl:value-of select="article/item-info/ce:pii"/>
> </TITLE>
> </HEAD>
> <BODY BGCOLOR="white">
> </BODY>
> </HTML>
> </xsl:template>
> </xsl:stylesheet>
>
>
> I would love to know how to get a value for my <TITLE> tag. What am I doing
> wrong, or misunderstanding?
>
> Dave Totten
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
>
>
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








