Jump to content

djmrman

Members
  • Content Count

    2
  • Joined

  • Last visited

Community Reputation

0 Neutral

About djmrman

  • Rank
    Newbie
  1. djmrman

    XML Data

    As the data is not separated within the opening and closing tags I thought they needed to have say <date>20190101</date> ect or am I wrong
  2. djmrman

    XML Data

    HI I'm a bit stuck at the moment I have worked out how to pull data from a well-formed XML file but I have a problem when it comes to an XML file that is supplied by some cinema software that i would like to use in an HTML file. It doesn't look well formed so my javascript is not working please see link below I need to parse the name duration rating and sessions etc to different divs. I could do this if it was well formed but not sure with how it is formed. Hope someone can help thanks jeremy http://starlightcinema.asuscomm.com:8090/xml/?xt=name&amp;cid=-1&amp;dt=20190101 The parser script that I have amended is <script type="text/javascript"> $(document).ready(function () { $.ajax({ type: "GET", url: "data.xml", dataType: "xml", success: xmlParser }); }); function xmlParser(xml) { $(xml).find("painting").each(function () { $("#container").append('<div class="painting"><img src="images/' + $(this).find("image").text() + '"width="200" height="225" alt="' + $(this).find("title").text() + '" /><br/><div class="title">' + $(this).find("title").text() + '<br/>$' + $(this).find("price").text() + '</div></div>'); $(".painting").fadeIn(1000); }); } </script>
×