Sign Up
Search
Options
search
Chat
Help
News
Log in
Not Logged in
Home
»
Boards
»
Stylus Studio Developer Network
»
XSLT Help and Discussion
»
ASP:DropDownList trigger in Xsl file
Topic
Topic Page
1
2
3
4
5
6
7
8
9
Prev Topic
Next Topic
next
Subject:
ASP:DropDownList trigger in Xsl file
Author:
Cameron Godfrey
Date:
26 Nov 2007 06:53 PM
Hi there, I have am xsl file containing a DropDownList. The DDL is set to AutoPostBack but I'm having trouble firing the onselect_edIndexChange event.
On another note, I'm wondering about the best way to pass the value of the selected index back into the xsl transform as a variable on postback.
I'm using VB.NET w/xml + xsl
Code:
<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="
http://www.w3.org/1999/XSL/Transform"
xmlns:asp="remove"
xmlns:msxsl="urn:schemas-microsoft-com:xslt"
xmlns:aqua="urn:aquaterra.org">
<msxsl:script implements-prefix="aqua" language="VB">
<!--Server-side scripting starts here-->
</msxsl:script>
<xsl:param name="articleid"/>
<xsl:param name="contributorid" select="0" />
<xsl:template match="contributors">
<xsl:for-each select="user">
<xsl:choose>
<xsl:when test="@id=$contributorid">
<div id="author">
<h6 style="margin-bottom: 0;">Written by</h6>
<div class="name">
<a href="#">
<xsl:value-of select="name"/>
</a>
</div>
<div class="desc">
<xsl:value-of select="brief" disable-output-escaping="yes"/>
</div>
<form id="articlesForm" runat="server">
<asp:DropDownList ID="articlesDd" CssClass="byauthor" onselect_edIndexChanged="getArticleValue" runat="server" AutoPostBack="true">
<asp:ListItem value="-1">Articles by this author:</asp:ListItem>
<xsl:for-each select="articles/article">
<xsl:choose>
<xsl:when test="@id!=$articleid">
<asp:ListItem value="{@id}">
<xsl:value-of select="title"/>
</asp:ListItem>
</xsl:when>
</xsl:choose>
</xsl:for-each>
</asp:DropDownList>
</form>
</div>
<div id="article">
<xsl:for-each select="articles/article">
<xsl:choose>
<xsl:when test="@id=$articleid">
<div id="top">
<div id="category">
<a href="#">
<xsl:value-of select="cat"/>
</a>
</div>
</div>
<h5>
<xsl:value-of select="title"/>
</h5>
<h6>
<xsl:value-of select="head"/>
</h6>
<p>
<xsl:value-of select="body" disable-output-escaping="yes"/>
</p>
</xsl:when>
</xsl:choose>
</xsl:for-each>
</div>
</xsl:when>
</xsl:choose>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
top
Subject:
ASP:DropDownList trigger in Xsl file
Author:
Tony Lavinio
Date:
26 Nov 2007 07:43 PM
This is a support forum for Stylus Studio users, asking questions
about using XSLT with Stylus Studio. It is not for general-purpose
XSLT questions.
Please ask in an ASP-specific forum or on the Mulberry Technologies
xsl-list.
Topic Page
1
2
3
4
5
6
7
8
9
Prev Topic
Next Topic
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 to Conference:
Select Conference
Stylus Studio Feature Requests
Stylus Studio Technical Forum
Website Feedback
XSLT Help and Discussion
XQuery Help and Discussion
Stylus Studio FAQs
Stylus Studio Code Samples & Utilities
Stylus Studio Announcements
go
Log In Options
Username:
Password:
Site Map
|
Privacy Policy
|
Terms of Use
|
Trademarks
Stylus Scoop XML Newsletter:
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.