Refreshing part of an XML/XSL page and JS

Discussion in 'Javascript' started by Anthony, Jan 13, 2006.

  1. Anthony

    Anthony Guest

    My goal is to have an interactive web form where users can view
    hierarchial data with the ability to add items to the system and have
    just the part of the webpage that needs to be updated be refreshed.
    However I've been working on it for a few days and still cant figure
    out how to put it together.

    task.xml - containing the XML data from a database
    task.xsl - containing the transformation to turn the above XML data
    into XHTML
    task.js - JS code
    partial.xml - containing XML data for a particular node in the XML
    document above (task.xml) that I want to have updated (for demo
    purposes, this is a static document)

    I have explored the following methods (in order from easiest to most
    difficult):
    1. Try to use JS to update the XML document and have the browser
    re-render it using XSL. I've come to the conclusion I cant do it this
    way (at least with the knowledge and google-fu I have now).
    2. Use a client side transformation using the transform tag inside the
    partial XML and insert the appropriate XHTML node into the new page in
    place of the old one. This resulted in nothing being rendered where the
    updated information was supposed to be.
    3. Use a server side transformation on the partial XML and insert the
    root XHTML node into the new page in place of the old one. This
    resulted in just the text elements within the XHTML to be rendered,
    none of the other tags (DIVs, BRs, etc) were rendered.
    4. Use responseText instead of responseXML, but I really really really
    want to stay away from innerHTML. Plus, the text is just text and I
    cant perform any node/element methods using it (which would be nice
    down the road).

    To see what code I have now:
    http://24.234.139.244/stt/task.xml
    http://24.234.139.244/stt/task.xsl
    http://24.234.139.244/stt/task.js
    http://24.234.139.244/stt/partial.xml

    I'm looking for suggestions on how to implement the functionality I am
    trying to write, I dont necessarily need line-for-line code (though if
    you want to write it or point me to a place where its written already,
    I wouldnt mind).

    Thanks.

    -Anthony
     
    Anthony, Jan 13, 2006
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Jules
    Replies:
    7
    Views:
    4,719
    Robert Frost-Bridges
    Sep 6, 2004
  2. Replies:
    1
    Views:
    3,613
    A. Bolmarcich
    May 27, 2005
  3. Harlan Messinger

    Self-refreshing and non-self-refreshing controls

    Harlan Messinger, Aug 4, 2006, in forum: ASP .Net
    Replies:
    1
    Views:
    460
    =?Utf-8?B?Y2xpY2tvbg==?=
    Aug 4, 2006
  4. Harlan Messinger

    Self-refreshing and non-self-refreshing controls

    Harlan Messinger, Aug 3, 2006, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    188
    Harlan Messinger
    Aug 3, 2006
  5. Refreshing Part of a Page

    , Feb 15, 2006, in forum: Javascript
    Replies:
    5
    Views:
    89
    Randy Webb
    Feb 15, 2006
Loading...

Share This Page