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)
-> - Stylus Studio - Registrar en o... (1)
-> + Stylus Studio - Registrar en o... (2)
-> + Can a pipeline send a file by ... (2)
-> + After Updateing WIN10 to WIN11... (12)
-> + Where do I add the custom java... (3)
-> + Where is the Diagram tab? (5)
-> + Applying XSLT to Word DOCX/XML (2)
-> - CSV conversion via ConvertToXM... (1)
-> + Text symbols in SS not same as... (4)
-> + Exposing xquery as webservice ... (6)
-> + Syntax Identifier (2)
-> + Saving a Converted XML as an X... (5)
-> + Output document cannot be pars... (4)
-> - Archiving output from conversi... (1)
-> + EDIFACT guideline from Stylus ... (3)
-> + CSV file putting all the data ... (5)
-> + Can't install Home version 64b... (5)
-> + presale - Can I covers this sc... (5)
-> + Problem with UNB (5)
-> + Splitting EDIFACT files pipeli... (4)
-- [1-20] [21-40] [41-60] Next
+ Website Feedback (249)
+ XSLT Help and Discussion (7625)
+ XQuery Help and Discussion (2017)
+ Stylus Studio FAQs (159)
+ Stylus Studio Code Samples & Utilities (364)
+ Stylus Studio Announcements (113)
Topic  
Postnext
pankaj beniwalSubject: Hyperlink in xsl
Author: pankaj beniwal
Date: 17 Aug 2006 01:30 AM
Following is my XML document.

<root>
<page>2</page>
<totalPage>7</totalPage>
</root>

and i want the output in following manner...
1 [2] 3 4 5 6 7

all the values except 2,which is the value of page, should be hyperlinked. When one click on any of value then series become change suppose.. one click on 4 then output should be in follwing manner..
1 2 3 [4] 5 6 7
except 4 all should be hyper link.


followin is not workin when i click on hyperlink...[suppose init values are pageValue = 2, noOfPage=7 and count = 1 ]
-----------------------------------------------------
<xsl:template name="PageCount">
<xsl:param name="pageValue"/>
<xsl:param name="noOfPage"/>
<xsl:param name="count"/>
<xsl:choose>
<xsl:when test="$noOfPage > $count ">
<xsl:choose>
<xsl:when test="$count = $pageValue">
<xsl:value-of select="$count"/>
</xsl:when>
<xsl:otherwise>
<a href="{$count}">
<xsl:value-of select="$count"/>
</a>
<xsl:value-of select="' '"/>
</xsl:otherwise>
</xsl:choose>
<xsl:call-template name="PageCount">
<xsl:with-param name="pageValue" select="Page"/>
<xsl:with-param name="noOfPage" select="NoOfPage"/>
<xsl:with-param name="count" select="$count + 1"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise>
<xsl:choose>
<xsl:when test="$pageValue= $noOfPage">
<xsl:value-of select="$count"/>
</xsl:when>
<xsl:otherwise>
<a href="{$count}"> <xsl:value-of select="$count"/>
</a>
</xsl:otherwise>
</xsl:choose>
</xsl:otherwise>
</xsl:choose>
</xsl:template>

-----------------------------------------------------

Posttop
Tony LavinioSubject: Hyperlink in xsl
Author: Tony Lavinio
Date: 17 Aug 2006 07:56 AM
Please do not cross-post.
You posted this already in "XSLT Help and Discussion"

   
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.