Re: XML + ASP

From: Robert J Egan (rob_j_egan_at_hotmail.com)
Date: 06/01/04


Date: Tue, 1 Jun 2004 13:27:01 +0100

Not sure where this should go as the output works fine when using a xml file
saved to my server, but when hitting the same result on a remote it doesn't.
The output is handled by a '.xsl' file, which outputs HTML as follows....

<html>
<body>
<h2>Courses</h2>
<table border="1">
<tr>
<td colspan="9">Search Phrase</td>
</tr>
<tr>
<td colspan="9">Records Returned</td>
</tr>
<tr bgcolor="#9acd32">
<th>CourseId</th>
<th>LDCS</th>
<th>Name</th>
<th>QualificationType</th>
<th>Description</th>
<th>LearnDirectFlag</th>
<th>Venue</th>
<th>AttendanceType</th>
<th>StartDetails</th>
</tr>
<tr>
<td>4988812</td>
<td>AK.6,FN.343</td>
<td>Accounting with French BA (Hons)</td>
<td>First Degree</td>
<td>3 year full time/ up to 8 years part time course run by Middlesex
University</td>
<td>TC</td>
<td>Hendon Campus</td>
<td>Full Time</td>
<td>Sep/04</td>
</tr>
<tr>
<td>4081296</td>
<td>AK.6,FN.343</td>
<td>Accounting with French BA (Hons)</td>
<td>First Degree</td>
<td>3 year full time/ up to 8 years part time course run by Middlesex
University</td>
<td>TC</td>
<td>Middlesex University</td>
<td>Full Time</td>
<td>Sep/04</td>
</tr>
................. etc

</table>
</body>
</html>

-------------

"Mark Schupp" <mschupp@ielearning.com> wrote in message
news:%23ZiqPMMREHA.1388@TK2MSFTNGP09.phx.gbl...
> Response.ContentType = "text/xml"
> Response.Write <xml string here>
> Response.End
>
> --
> Mark Schupp
> Head of Development
> Integrity eLearning
> www.ielearning.com
>
>
> "Robert J Egan" <rob_j_egan@hotmail.com> wrote in message
> news:O6mY79LREHA.3504@TK2MSFTNGP09.phx.gbl...
> > Hi i'm trying to search a remote website page. The form returns xml
> > information, though the page extension is missing. I retrieve the
> > information and write it to the screen. So far so good - However i
cannot
> > format this information in anyway. A copy of the returned information
> saved
> > to my server results in the xml data being formatted and displayed as
> > intended! Can anyone explain to me why one would work but not the other.
> >
> > Regards
> >
> > Robert Egan
> >
> > -- Code Below --
> >
> > str_HC_url - variable formed from form information
> >
> > xml.Open "GET", str_HC_url , false - line of code used - does not work
> >
> > The above brings back info but cannot be formatted using code below.
> >
> > Set xml = Server.CreateObject ("Microsoft.XMLHTTP")
> > xml.Open "GET", "http://www.accessburnley.co.uk/xml/asp/cdcatalog.xml"
,
> > false - alternate line of code - does work.
> > xml.Send
> > text = xml.ResponseText
> >
> > If xml.Status = 200 Then
> > Set oResponseXML = xml.ResponseXML
> > bXMLLoadError = False
> > Else
> > Response.Write("<font color=""red"">Page Error: Could not load XML
> from
> > remote server</font><br>")
> > bXMLLoadError = True
> > End If
> >
> > Set xml = nothing
> >
> > If Not bXMLLoadError Then
> >
> > // Load XML
> > set oXML = Server.CreateObject("Microsoft.XMLDOM")
> > oXML.Async = false
> > oXML.Load(oResponseXML)
> >
> > // Load XSL
> > set oXSL = Server.CreateObject("Microsoft.XMLDOM")
> > oXSL.Async = False
> > 'oXSL.Load(Server.MapPath("HotCourses.xsl"))
> > oXSL.Load(Server.MapPath("cdcatalog_ex3.xsl"))
> > // Transform
> > 'Response.Write(oXML.transformNode(oXSL))
> >
> > End If
> >
> >
>
>



Relevant Pages

  • Re: Looking for XML driven reporting tool
    ... I am using FOP http://xml.apache.org/fop/ to generate PDF's. ... The 2 main steps here are first converting your XML data into XSL:FO format ... > server using XML documents as the data source. ...
    (microsoft.public.data.xmlanalysis)
  • Re: Looking for XML driven reporting tool
    ... I am using FOP http://xml.apache.org/fop/ to generate PDF's. ... The 2 main steps here are first converting your XML data into XSL:FO format ... > server using XML documents as the data source. ...
    (microsoft.public.dotnet.xml)
  • Re: read new word XML in MacOSX Word X ?
    ... The XML file format is really XML, but the file is automatically zipped by Word when it was saved. ... I don't have a new format document around, but maybe Stuffit Expander can extract the real XML from the new Word document. ... Word FAQ: http://www.word.mvps.org/ ...
    (microsoft.public.mac.office.word)
  • Re: VBSCRIPT & XML - Easy solution?
    ... This can easily be done in ASP by processing the XML file in one of three ways: ... Actual syntax varies depending on what you back end server is running. ... Client side assuming you ONLY what to support IE you could embed the XML as a Data Island and then use VBScript / Javascript to walk the nodes etc using the DOM. ...
    (microsoft.public.vstudio.development)
  • Re: CFD: XMLification of NOTES
    ... > I do not see any point to invent any other formats in days when XML ... XML is hard to work with in a standard text editor. ... There are clear costs to switching to XML - the format is worse to work ... This was a constraint on WHEN it could be needed to modify the XML file. ...
    (freebsd-arch)