onez Posted April 2, 2006 Posted April 2, 2006 I want this extension object to return a link. But the function does not execute in scripting events. It will execute if put as a "value-of". Actually, what I'm trying to do is create a new document each time a node is clicked so the node appears to embedded. Is this a good way to do this? public class DisplayX { public string Insert(XPathNodeIterator xni) { return @"top.location.href = 'C:\StockData\ZZZZZZZZ.htm';"; } } <?xml version="1.0" encoding="utf-8" ?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:DisplayXObj="urn:DisplayX"> <xsl:template match="FoundTable"> <xsl:value-of select="T2" /> <div onclick="top.location.href = 'C:/StockData/try.htm';">This link works</div> <div class="link" onclick="DisplayXObj:Insert(Node1)">This link tries to goto the text</div> <xsl:value-of select="DisplayXObj:Insert(Node1)" /> <-- This Displays! --> </xsl:template> </xsl:stylesheet> Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.