
November 7th, 2003, 02:09 AM
|
|
Junior Member
|
|
Join Date: Nov 2003
Posts: 2
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
Headlineripper problem with special characters
I have this headlineripping script up and running but special characters causes major problems. Is there any way to html encode, change character encoding or replace scandic letters ö ä and å with html code. And I think it must be done before parsing.
//start
Set xml = Server.CreateObject("Msxml2.ServerXMLHTTP")
theurl = "here is the url"
xml.Open "GET", theurl, False
xml.Send
//parsing
MyString = xml.responseText
strtolookfor = "<startlookingtext>"
endtolookfor = "<stoplookingtext>"
startleft = 1
//pasting
Response.Write("<someextrahtmlhere>" & theheadline & "<someextrahtmlhere>")
For example: If I use Server.HTMLEncode([theheadline]) to replace theheadline in pasting, it only encodes the mess what is already done. If the headline has ä ö or å for its last letter, string stops right there and causes <stoplookingtext> (some html tag) to crash.
|