Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

asp and rss

Status
Not open for further replies.

amiw

Programmer
Apr 1, 2003
113
GB
i have tried to run this code, below is the error message i get...


<?xml version=&quot;1.0&quot; encoding=&quot;ISO-8859-1&quot;?>
<% Response.Buffer = true
Response.ContentType = &quot;text/xml&quot;
Function ApplyXMLFormatting(strInput)
strInput = Replace(strInput,&quot;&&quot;, &quot;&amp;&quot;)
strInput = Replace(strInput,&quot;'&quot;, &quot;&apos;&quot;)
strInput = Replace(strInput,&quot;&quot;&quot;&quot;, &quot;&quot;&quot;)
strInput = Replace(strInput, &quot;>&quot;, &quot;&gt;&quot;)
strInput = Replace(strInput,&quot;<&quot;,&quot;&lt;&quot;)
ApplyXMLFormatting = strInput
End Function
%>
<rss version=&quot;2.0&quot;>
<channel>
<title>Recent Posts on ASPMessageboard.com</title>
<link> <description>ASPMessageboard.com is a site where developers of
Microsoft's Active Server Pages and Active Server Pages .NET
can come to ask questions and get answers!</description>
<language>en-us</language>
<copyright>Copyright 2003 Jupitermedia Corporation.
All Rights Reserved.</copyright>
<ttl>20</ttl>
<%
strConnect = &quot;DRIVER={Microsoft Access Driver(*.mdb)};DBQ=&quot; & Server.MapPath(&quot;rss.mdb&quot;)
Set objConn = Server.CreateObject (&quot;ADODB.Connection&quot;)
objConn.Open strConnect
strSQL = &quot;SELECT * FROM tblRss Order by Title Desc;&quot;
Set objRS = objConn.Execute(strSQL)
Do While Not objRS.EOF
%> <item>
<title><%=ApplyXMLFormatting(objRS(&quot;title&quot;).Value)%>
</title>
<link><%=ApplyXMLFormatting(objRS(&quot;link&quot;).Value)%>
</link>
<description><%=ApplyXMLFormatting(objRS(&quot;intro&quot;).Value)%></description>
</item>
<%
objRS.MoveNext
Loop
%>
</channel>
</rss>
<%
objRS.Close
Set objRS = Nothing

objConn.Close
Set objRS = Nothing
Set objConn = Nothing
%>


error message is
A string literal was expected, but no opening quote character was found. Error processing resource ' Line 14, Position 26

<font face=&quot;Arial&quot; size=2>
-------------------------^


any ideas?
thanks
M
 
What is returning that error message i have no idea because you dont tell us!

But if it is some XML processor (this is a XML forum after all) of any kind <font face=&quot;Arial&quot; size=2> is not valid XML. It would have to be: <font face=&quot;Arial&quot; size=[red]&quot;[/red]2[red]&quot;[/red]>



-pete
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top