[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Namespaces

Subject: Re: Namespaces
From: David Totten <xsl@xxxxxxxxxxxxxx>
Date: Tue, 10 Jun 2003 06:37:00 -0400
david totten
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 "&#160;">
> <!ENTITY copy "&#169;">
> <!ENTITY quote "&#34;">
> <!ENTITY rdquo "&#34;">
> <!ENTITY ldquo "&#34;">
> <!ENTITY reg   "&#174;">
> ]>
> 
> <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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.