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

Xalan: local namespace declaration and XSL transformat

Subject: Xalan: local namespace declaration and XSL transformation problem
From: "Matthias O. Will" <m.o.will@xxxxxx>
Date: Tue, 03 Apr 2001 18:52:36 +0200
xsl local namespace
Hi,

I am converting XML to XML. My target DTD includes a local namespace,
which is declared in a separate DTD. When running Xalan, I get lots of
scrambled output, but I don't know where to start looking for remedy.

This is going to be long, and I'm starting by explaining what my target
DTD looks like:

<!ENTITY % dlmeta SYSTEM "http://www.dlmeta.de/dlmeta/2000/DLmeta.dtd">
%dlmeta;
<!ENTITY % AriadneInclude SYSTEM
"http://www.informatik.uni-freiburg.de/~will/Ariadne/ariadne_local.dtd">
%AriadneInclude;

The first DTD includes some entities, which are specified in a separate
file (and included in DLmeta.dtd), such as

<!ENTITY % a.Language '
        Scheme          (ISO639-2)              #REQUIRED
        LanguageName       (...)		#REQUIRED'>


The (...) stands for an explicit list of three-letter language
abbreviations according to ISO 639-2, which I have not expanded here.

Second, one element, say Viror:InteractivityLevel, has an attribute list
defined as 

	<!ATTLIST Viror:InteractivityLevel   %a.Language;>

(other local elements have the same attribute list, too). My target DTD
has an element 'Local' defined as ANY, and this is where the local
namespace fields go, starting with <Viror:Local>, which is the head of
everything else:

	<!ELEMENT Viror:Local (Viror:Pedagogical, Viror:Technical)>

Third, I am associating an URL with the namespace in the XSL stylesheet
so it appears in my output documents when running the interpreter:

	 <Viror:Local xmlns:Viror="http://www.dlmeta.de/local/2000/bsz">

What is the consequence of doing this? What kind of document/object does
this URL have to reference?

Now, the problem when running Xalan is that I get the following error
messages

Line #317, Column #41: template match='DidacticalContext' 
Illegal attribute name: Scheme
Illegal attribute name: LanguageName
Line #325, Column #35: template match='CourseLevel' 
Illegal attribute name: Scheme
Illegal attribute name: LanguageName
Line #333, Column #39: template match='DifficultyLevel' 
Illegal attribute name: Scheme
Illegal attribute name: LanguageName
Line #341, Column #42: template match='InteractivityLevel' 
Illegal attribute name: Scheme
Illegal attribute name: LanguageName
Line #349, Column #39: template match='SemanticDensity' 
Illegal attribute name: Scheme
Illegal attribute name: LanguageName
Line #364, Column #38: template match='DocumentHandle' 
Line #370, Column #38: template match='FileMediaTypes' 
Illegal attribute name: Scheme
Line #370, Column #38: template match='FileMediaTypes' 
Illegal attribute name: Scheme
Line #370, Column #38: template match='FileMediaTypes' 
Illegal attribute name: Scheme
Line #370, Column #38: template match='FileMediaTypes' 
Illegal attribute name: Scheme
Line #377, Column #39: template match='OperatingSystem' 
Line #385, Column #49: template match='OtherPlatformRequirements' 
Illegal attribute name: Scheme
Illegal attribute name: LanguageName
Illegal attribute name: Scheme
Illegal attribute name: LanguageName
Line #398, Column #43: template match='InstallationRemarks' 
Illegal attribute name: Scheme
Illegal attribute name: LanguageName

When I declare the namespace in my XSL stylesheet as

	<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0"
                xmlns:Viror="http://www.dlmeta.de/local/2000/bsz">

my output says

	<DLmeta xmlns:Viror="http://www.dlmeta.de/local/2000/bsz">

and my output is ok. How do I achieve that xmlns:Viror is associated
with my <Local> element instead of <DLmeta>?

Do I need to declare my namespace (Viror) in the local DTD? If yes, how
do I do it? 

Thanks for your help and best regards,
Matthias O. Will

-- 

---------------------------------------------------------------------
PLEASE NOTE THAT MY MAIL ADDRESS m.o.will@xxxxxx WILL BE DISCONTINUED
AND USE m.o.will@xxxxxx TO SEND ME YOUR E-MAILS! THANK YOU VERY MUCH!
--------------------------------------------------------------------

Matthias O. Will (m.o.will@xxxxxx)                       <>< 
Institute of Computer Science,       University of Freiburg
Georges-Koehler-Allee, Bldg. 51, D-79110 Freiburg,  Germany	 
Phone:   +49-761-203-8170             Fax: +49-761-203-8162  
URL:     http://ad.informatik.uni-freiburg.de/~will

 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.