XSL with tooltips

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Ofay

    #1

    XSL with tooltips

    I am trying to do a mouseover with tooltips with an XSL stylesheet. I
    want to be able to pick data from the XML using the syntax
    <xsl:value-of select="CHALLEN GE_REMARKS"/> How do I send the data
    from this element to the doToolTip function.

    Ex.
    <td> onmouseover="do Tooltip(event,< xsl:value-of
    select="CHALLEN GE_REMARKS"/>) </td>

    This does not work. I have tried putting the element in a var and
    this works except when there are multiple rows the mouseover tooltip
    only displays the data for the last row for all rows.

    Any thoughts?
  • George Hester

    #2
    Re: XSL with tooltips

    Maybe:

    <td><xsl:attrib ute name="onmouseov er">JavaScript: doTooltip(event ,<xsl:value-of select="CHALLEN GE_REMARKS" />)</xsl:attribute></td> or something like that. You may need a seperate js file with the JavaScript code and import that near the top of your xsl:

    <xsl:template match="/">
    <HTML>
    <HEAD>
    <TITLE>Menu <xsl:value-of select="TOPICLI ST/@TYPE" /></TITLE>
    <SCRIPT LANGUAGE="JavaS cript" SRC="name.js"></SCRIPT>
    ....

    --
    George Hester
    _______________ _______________ ____
    "Ofay" <ofay.bell@eds. com> wrote in message news:578ef549.0 409281235.3af99 5e3@posting.goo gle.com...[color=blue]
    > I am trying to do a mouseover with tooltips with an XSL stylesheet. I
    > want to be able to pick data from the XML using the syntax
    > <xsl:value-of select="CHALLEN GE_REMARKS"/> How do I send the data
    > from this element to the doToolTip function.
    >
    > Ex.
    > <td> onmouseover="do Tooltip(event,< xsl:value-of
    > select="CHALLEN GE_REMARKS"/>) </td>
    >
    > This does not work. I have tried putting the element in a var and
    > this works except when there are multiple rows the mouseover tooltip
    > only displays the data for the last row for all rows.
    >
    > Any thoughts?[/color]

    Comment

    • Ofay

      #3
      Re: XSL with tooltips

      Thanks George:

      I actually did some further research and found a solution which works:

      <td align="center" width="120">

      <a>
      <xsl:attribut e name="style"><x sl:text>color:# 000000;</xsl:text></xsl:attribute>
      <xsl:attribut e name="href"><xs l:value-of
      select="substri ng(CHALLENGE_RE MARKS,1,12)"/></xsl:attribute>
      <xsl:attribut e
      name="onMouseOv er">doTooltip(e vent,'<xsl:valu e-of
      select="CHALLEN GE_REMARKS"/>')
      <xsl:text> </xsl:text>return true<xsl:text>
      </xsl:text></xsl:attribute>
      <xsl:attribut e name="onmouseou t">hideTip() </xsl:attribute>
      <xsl:value-of select="substri ng(CHALLENGE_RE MARKS,1,12)"/>

      </a>
      </td>

      Again Thanks.

      "George Hester" <hesterloli@hot mail.com> wrote in message news:<07L6d.250 846$bp1.218979@ twister.nyroc.r r.com>...[color=blue]
      > Maybe:
      >
      > <td><xsl:attrib ute
      > name="onmouseov er">JavaScript: doTooltip(event ,<xsl:value-of
      > select="CHALLEN GE REMARKS" />)</xsl:attribute></td> or something like
      > that. You may need a seperate js file with the JavaScript code and
      > import that near the top of your xsl:
      >
      > <xsl:template match="/">
      > <HTML>
      > <HEAD>
      > <TITLE>Menu <xsl:value-of select="TOPICLI ST/@TYPE" /></TITLE>
      > <SCRIPT LANGUAGE="JavaS cript" SRC="name.js"></SCRIPT>
      > ...
      >
      > --
      > George Hester
      >
      > "Ofay" <ofay.bell@eds. com> wrote in message
      > news:578ef549.0 409281235.3af99 5e3@posting.goo gle.com...[color=green]
      > > I am trying to do a mouseover with tooltips with an XSL stylesheet. I
      > > want to be able to pick data from the XML using the syntax
      > > <xsl:value-of select="CHALLEN GE REMARKS"/> How do I send the data
      > > from this element to the doToolTip function.
      > >
      > > Ex.
      > > <td> onmouseover="do Tooltip(event,< xsl:value-of
      > > select="CHALLEN GE REMARKS"/>) </td>
      > >
      > > This does not work. I have tried putting the element in a var and
      > > this works except when there are multiple rows the mouseover tooltip
      > > only displays the data for the last row for all rows.
      > >
      > > Any thoughts?[/color][/color]

      Comment

      • George Hester

        #4
        Re: XSL with tooltips

        Cool thanks. I'll be checking that out.

        --
        George Hester
        _______________ _______________ ____
        "Ofay" <ofay.bell@eds. com> wrote in message news:578ef549.0 409300626.19d60 a85@posting.goo gle.com...[color=blue]
        > Thanks George:
        >
        > I actually did some further research and found a solution which works:
        >
        > <td align="center" width="120">
        >
        > <a>
        > <xsl:attribut e name="style"><x sl:text>color:# 000000;</xsl:text></xsl:attribute>
        > <xsl:attribut e name="href"><xs l:value-of
        > select="substri ng(CHALLENGE_RE MARKS,1,12)"/></xsl:attribute>
        > <xsl:attribut e
        > name="onMouseOv er">doTooltip(e vent,'<xsl:valu e-of
        > select="CHALLEN GE_REMARKS"/>')
        > <xsl:text> </xsl:text>return true<xsl:text>
        > </xsl:text></xsl:attribute>
        > <xsl:attribut e name="onmouseou t">hideTip() </xsl:attribute>
        > <xsl:value-of select="substri ng(CHALLENGE_RE MARKS,1,12)"/>
        >
        > </a>
        > </td>
        >
        > Again Thanks.
        >
        > "George Hester" <hesterloli@hot mail.com> wrote in message news:<07L6d.250 846$bp1.218979@ twister.nyroc.r r.com>...[color=green]
        > > Maybe:
        > >
        > > <td><xsl:attrib ute
        > > name="onmouseov er">JavaScript: doTooltip(event ,<xsl:value-of
        > > select="CHALLEN GE REMARKS" />)</xsl:attribute></td> or something like
        > > that. You may need a seperate js file with the JavaScript code and
        > > import that near the top of your xsl:
        > >
        > > <xsl:template match="/">
        > > <HTML>
        > > <HEAD>
        > > <TITLE>Menu <xsl:value-of select="TOPICLI ST/@TYPE" /></TITLE>
        > > <SCRIPT LANGUAGE="JavaS cript" SRC="name.js"></SCRIPT>
        > > ...
        > >
        > > --
        > > George Hester
        > >
        > > "Ofay" <ofay.bell@eds. com> wrote in message
        > > news:578ef549.0 409281235.3af99 5e3@posting.goo gle.com...[color=darkred]
        > > > I am trying to do a mouseover with tooltips with an XSL stylesheet. I
        > > > want to be able to pick data from the XML using the syntax
        > > > <xsl:value-of select="CHALLEN GE REMARKS"/> How do I send the data
        > > > from this element to the doToolTip function.
        > > >
        > > > Ex.
        > > > <td> onmouseover="do Tooltip(event,< xsl:value-of
        > > > select="CHALLEN GE REMARKS"/>) </td>
        > > >
        > > > This does not work. I have tried putting the element in a var and
        > > > this works except when there are multiple rows the mouseover tooltip
        > > > only displays the data for the last row for all rows.
        > > >
        > > > Any thoughts?[/color][/color][/color]

        Comment

        Working...