Re: embedding XML in HTML

Discussion in 'XML' started by john.nance@ctrls.com, May 28, 2004.

  1. Guest

    If you don't want to change all your HTML then you can always cheat
    using DHTML. Mark a placeholder on your pages such as
    <div id="helloworld"></div>

    Then use the page onload event to run the transform and some javascript
    to change the innerHTML of the div.

    <SCRIPT language="javascript">
    function doStart()
    {
    LoadXML('helloworld');
    }
    </SCRIPT>

    <body onLoad="javascript:doStart()">

    My LoadXML function loads a standard (fixed) XML file and uses the
    parameter to define both the package to include and the name of the DIV
    to modify.

    I've used it on a couple of websites to embed dynamic content on
    predefined page content.
    , May 28, 2004
    #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. Kevin
    Replies:
    1
    Views:
    497
    Martin Honnen
    Dec 17, 2003
  2. Mark Van Orman

    embedding xml in xml as non-xml :)

    Mark Van Orman, Sep 14, 2004, in forum: XML
    Replies:
    5
    Views:
    475
    Patrick TJ McPhee
    Sep 15, 2004
  3. Replies:
    1
    Views:
    585
    Travis Newbury
    Sep 13, 2006
  4. DartGuru
    Replies:
    4
    Views:
    2,696
    Chaddy2222
    Oct 23, 2007
  5. Replies:
    5
    Views:
    543
Loading...

Share This Page