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

RE: Table Span not working

Subject: RE: Table Span not working
From: "Scott Trenda" <Scott.Trenda@xxxxxxxx>
Date: Mon, 5 Jan 2009 22:05:28 -0600
RE:  Table Span not working
It looks like you just forgot the curly braces in the colspan
attribute-value-template. Try this:

        <th bgcolor="#C4C4FF"
colspan="{($colend-$colst)+1}"><xsl:apply-templates/></th>

~ Scott

-----Original Message-----
From: V.Ramkumar [mailto:v.ramkumar@xxxxxxxxxxxxxxxxxxxxxx]
Sent: Monday, January 05, 2009 9:47 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:  Table Span not working

Hi List,

I am doing XSL style sheet for XML view. In table, span not able to get,
Please correct me any mistake in the below code.

 XSL
=====
The below my code not giving expected result/span in IE.

    <xsl:template match="thead/row/entry">
        <xsl:variable name="colst"
select="translate(@namest,'col','')"/>
        <xsl:variable name="colend"
select="translate(@nameend,'col','')"/>
        <th bgcolor="#C4C4FF"
colspan="($colend-$colst)+1"><xsl:apply-templates/></th>
    </xsl:template>

 XML
======
Four column table contains a header spanned row like below.

<row row-type="straddle-head">
<entry align="center" nameend="col3" namest="col2">PIN-a
&#x0394;&#x03C0;
(mN/m)</entry>
<entry align="center" nameend="col5" namest="col4">PIN-b
&#x0394;&#x03C0;
(mN/m)</entry>
</row>

Regards,
Ramkumar

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.