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

Re: Breaking up XML(XHTML) into pages

Subject: Re: Breaking up XML(XHTML) into pages
From: "Leonidas Kanellos" <leonidaskanellos@xxxxxxxxxxx>
Date: Tue, 25 Mar 2003 12:31:05 +0000
confused msn names




Hi David,

Thanks for the reply.

I put //div[@class='section'][popsition()=1]//h2 in XPath and it is true. It gives the first h2 section.

I change <xsl:param name="page_number" select=" '5' "/>

to <xsl:param name="page_number" select=" 5 "/> but i cannot get the section that i want its time. In this case, the fifth h2 section.
I get all the text instead.


Do you think that the problem exist in this code:

<!-- manage h2 elements -->
<xsl:template match="//xhtml:div[@class='section']/xhtml:h2">

I use condition in order not to have the external (<a>) h2 at the output
<xsl:choose>
<xsl:when test="./xhtml:a">
</xsl:when>
<xsl:otherwise>

Here i try to insert the parameter.
Maybe it would be better to have an if condition here but i must have the choose condition as well for the external links.


<input name="page_number" value="{$page_number}"/>
<xsl:value-of select="*">
</xsl:value-of>
<xsl:apply-templates/>

I give an id to all the h2 in order to link to them externaly or internaly.

<h2 class="section" id="{generate-id()}">
<a name="{generate-id()}">
<xsl:value-of select="."/>
</a>
</h2>

</xsl:choose>
</xsl:template>


At the output for example, i get for the third h2 section this:
<input xmlns="" name="page_number" value="" />Enquiries<h2 xmlns="" class="section" id="h243592048">


But i don't know how i will pick it up at the url.


I hope i explained my problem well cause i am confused as well:)


Regards

Leo



_________________________________________________________________
MSN 8 with e-mail virus protection service: 2 months FREE* http://join.msn.com/?page=features/virus



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.