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

Change bar in xsl

Subject: Change bar in xsl
From: "Alexandre Moraes" <alexmoraes@xxxxxxxxx>
Date: Tue, 13 Nov 2007 10:34:08 -0200
 Change bar in xsl
Hi,

    I4m trying to use change-bar in xsl. I created an external table
with a column that would be my change bar but i still have a problem.
This problem is when I need to write a table and it has two <para>
inside an entry. I need to put the change bar just in the first line,
not in the full row.Revtag says if the content changed. My xml is:

<table>
  <thead>
   <row>
      <entry>
        <para>
           First para Header
       </para>
      </entry>
     <entry>
       <para>
          Second para Header
       </para>
      </entry>
   </row>
  </thead>
  <tbody>
    <row>
      <entry>
         <para>
             First entry first para body
         </para>
      </entry>
      <entry>
         <para>
            Second entry first para body
         <para>
      <entry>
     </row>
     <row>
      <entry>
         <para>
             <revtag>First para first entry body</revtag>
         </para>
         <para>
             Second para first entry body
         </para>
      </entry>
      <entry>
         <para>
            First para second entry body
         <para>
      <entry>
     </row>
  </tbody>
</table>

My xsl is:

<xsl:template match="table">

	<table border="1" cellpadding="1" cellspacing="1">
		<xsl:apply-templates/>
	</table>

	</xsl:template>
	<xsl:template match="row">
		<tr>
			<xsl:call-template name="BarraRev"/>(Create a td and if find
<revtag> set background = black.)
			<td>
				<xsl:call-template name="Identation"/>
			</td>
			<xsl:apply-templates/>
		</tr>
	</xsl:template>


	<xsl:template match="entry">
		<td>
			<xsl:apply-templates/>
		</td>
	</xsl:template>

        <xsl:template match=para>
         <xsl:apply-templates/>
          <br/>
        </xsl:tempalte>


If someone has another solution.

Thanks

Alexandre

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.