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

Re: inheritance and encapsulation in xslt? / xslt for

Subject: Re: inheritance and encapsulation in xslt? / xslt for xlink?
From: Howard Stearns <stearns@xxxxxxxxxxxx>
Date: Mon, 21 Jul 2003 21:01:41 -0400
xslt inherit
I didn't follow how this would work any number of levels deep.

It's ok if we only have us-gaap-ci-2html.xsl doing the basic transformations, and a CSS stylesheet based on @class to handle things that need to be different. Very cute.

But in fact ci is part of us-gaap which is part of the basic financial reporting taxonomy. Acme Corp may have many operating levels (subsidiaries, divisions, etc.). There may be more industry specific levels between us-gaap-ci and individual companies like Acme. A stylesheet any of these levels should be able to define behavior that applies to all the more specific levels.

I'm not very familiar with real CSS, and maybe there's a way to inherit behavior. But I would guess the inheritance behavior would have to be generated somehow. How would CSS know which elements (which @classes) inherit from each other?

Besides, I actually want the .xsl to be generating results for conformance testing. It won't necessarilly be XHTML output subject to CSS.

Robert Koberg wrote:
...
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:lsb="http://livestoryboard.com/lsb/schemas/2003/03/config" xmlns:c="http://livestoryboard.com/lsb/schemas/2003/03/content" exclude-result-prefixes="c lsb">


<xsl:template match="c:*">
<div class="{local-name()}">
<xsl:copy-of select="@*"/>
<xsl:apply-templates/>
</div>
</xsl:template>
</xsl:stylesheet>


This can get modified as needed, but it covers most (of our) needs. You
would then handle your unique look and feel through CSS. Of course this type
of thing just moves the problem somewhere else, but it is much easier for a
client to deal with CSS than XSL.


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.