#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2011
    Posts
    56
    Rep Power
    4

    XSLT / XPATH how to add a column based on javascript


    Hi,

    I have an XSL file which transforms an XML file into a simple table (with a limited amount of information).

    I have a html file with a javascript form which allows the user to filter which nodes to show (and they get show in the same format as above, using same XSL file).

    It all works fine; implemented by overwriting the value of the select in a for-each statement which displays the required nodes (in the XSL) from the javascript in the HTML file. However, with some searches, I want an extra column of info from the XML file added to the resulting table.

    I've tried to pass a variable or param to the XSL file and use as a condition to show the extra column, but it hasn't worked.

    Perhaps there is a template solution, like call an extra template in the XSL file?

    Any ideas would be great.

    Thanks
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2011
    Posts
    56
    Rep Power
    4
    anyone?
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2011
    Location
    Abilene, Texas
    Posts
    69
    Rep Power
    6
    I've tried to pass a variable or param to the XSL file and use as a condition to show the extra column, but it hasn't worked.
    This should've worked if you're XSLT transformer is passing the new param.

IMN logo majestic logo threadwatch logo seochat tools logo