XML Editor
Sign up for a WebBoard account Sign Up Keyword Search Search More Options... Options
Chat Rooms Chat Help Help News News Log in to WebBoard Log in Not Logged in
Conferences Close Tree View
+ Stylus Studio Feature Requests (1192)
+ Stylus Studio Technical Forum (14621)
+ Website Feedback (249)
- XSLT Help and Discussion (7625)
-> + Use of before and after string (3) Sticky Topic
-> - How do I substitute element ty... (1)
-> + How does one add working days ... (4)
-> - Help, I have existing XLT and... (1)
-> + Need help on XSLT issue - (2)
-> + EDI to XML Conversion (7)
-> - XML To JSON Conversion using X... (1)
-> + Formatting Paragraphs to same ... (2)
-> - Grouping of records (1)
-> + Problems with xsd 1.1 (4)
-> + XML to HL7 mapping (3)
-> + XSLT 3 and Iterate (2)
-> + XSL-FO to PDF preview (3)
-> + java.lang.RuntimeException: Er... (2)
-> + Create Acroforms with Stylus X... (2)
-> + How to change XSLT parameter s... (3)
-> + how to change format of the da... (2)
-> + Search "Next 8 Results " doesn... (2)
-> - Support for Git (1)
-> + newbee (8)
-- [1-20] [21-40] [41-60] Next
+ XQuery Help and Discussion (2017)
+ Stylus Studio FAQs (159)
+ Stylus Studio Code Samples & Utilities (364)
+ Stylus Studio Announcements (113)
Topic  
Postnext
Max HodgesSubject: Problem with attribute-sets, maybe bug?
Author: Max Hodges
Date: 26 Apr 2002 01:24 AM
I have an XSLT that includes a library.xsl. In this library file I define some attribute-sets. When I run my xsl using the SS processor, some use-attribute-sets statements work, but one that is nested in a called template doesn't. Why?

Also, if I run it from MSXML, none of the use-attribute-sets statements work. I'm confused. Who is out of spec? or is the spec ambigious? I need a working solution with MSXML.


Documentattrib_set.zip
ss project file set

Postnext
(Deleted User) Subject: Re: Problem with attribute-sets, maybe bug?
Author: (Deleted User)
Date: 26 Apr 2002 05:33 AM
At 01.36 26/04/2002 -0400, you wrote:
>From: "Max Hodges"
>
>I have an XSLT that includes a library.xsl. In this library file I define
>some attribute-sets. When I run my xsl using the SS processor, some
>use-attribute-sets statements work, but one that is nested in a called
>template doesn't. Why?

The use-attribute-sets in the //link template does work (the output shows
'font color=""' so it has been expanded) but it's the query that fails.
This because the template is called using

xsl:apply-templates
select="document($ref_doc_path)//external_links/link[position() mod 3 = 1]"

that makes the document context be the ref2.xml file; so the query
//color[@id=2] specified by the attribute-set will not find any definition.
A possible solution (not very library-friendly, however) would be to change
the query to be document('test.xml')//color[@id=2]


>Also, if I run it from MSXML, none of the use-attribute-sets statements
>work. I'm confused. Who is out of spec? or is the spec ambigious? I need a
>working solution with MSXML.

There is an error in the test.xsl stylesheet: the "font" elements have an
"use-attribute-sets" attribute instead of "xsl:use-attribute-sets". In this
case, Stylus is not following the specs by not checking that the attribute
is in the XSLT namespace.

Alberto

Posttop
Max HodgesSubject: Re: Problem with attribute-sets, maybe bug?
Author: Max Hodges
Date: 26 Apr 2002 06:20 AM
THANK YOU SO MUCH! I was making great progress on my project, and then I just hit a wall with these attribute issues. Excellent work on your part. I really appreciate it!

   
Download A Free Trial of Stylus Studio 6 XML Professional Edition Today! Powered by Stylus Studio, the world's leading XML IDE for XML, XSLT, XQuery, XML Schema, DTD, XPath, WSDL, XHTML, SQL/XML, and XML Mapping!  
go

Log In Options

Site Map | Privacy Policy | Terms of Use | Trademarks
Stylus Scoop XML Newsletter:
W3C Member
Stylus Studio® and DataDirect XQuery ™are from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2016 All Rights Reserved.