Forum Moderators: open

Message Too Old, No Replies

Handling ampersands in ROR feeds

         

docptl

9:07 pm on Jul 9, 2005 (gmt 0)

10+ Year Member



Hi - I've written an export process for my product database that generates an ror.xml file for search engines to (hopefully) read. As we sell rather a lot of AT&T telephone hardware, we have a lot of text and keywords with "AT&T" in it. When I browse the xml file I've created, it bombs at any line with an "&" in it, unless I use the HTML "&" convention.

This would be OK, except that I'm not sure if this looks the same to the Search engines. ie does "&" read the same as "&"?

Does anyone know about this issue?

Thanks

choster

1:28 pm on Jul 11, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



& is a reserved character in XML. You must escape ampersands as &, otherwise your XML is invalid.

For that matter, & is also a reserved character in HTML. You must escape ampersands as &, otherwise your HTML is invalid.

Google knows what an & is.

docptl

6:17 pm on Jul 11, 2005 (gmt 0)

10+ Year Member



Hi and thanks for info regarding the ampersands; I made the replacements and it seems OK.

However, I discovered that, when I browse the ror.xml feed, it also doesn't like registered trademark symbols or copyright symbols, even when replaced with their ampersand equivalents. I've even tried using the numeric version for the trademark - ®. I still get an error and thr browser stops reading the file at or around that spot.

Here's what it shows me:

XML page cannot be displayed
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.

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

An invalid character was found in text content. Error processing resource 'file:///C:/Phonesrc/WWW/v9page/ror.xml'. Line 2...

<desc>Panasonic 2.4 GHz FHSS cordless phones GigaRange&#174; Security&#174;LinkPlus

/desc>
<keywords>Panasonic KX-TG2386,KX-TG2386,2.4Ghz cordless phones, telephones answering machines,amplified,hearing impared,volume control,Panasonic telephones</keywords>
<image>http://www.thephonesource.com/kxtg2386.jpg</image>
<price>153.91</price>

athinktank

8:57 pm on Jul 16, 2005 (gmt 0)

10+ Year Member



Welcome to WebmasterWorld docptl,

You still having problems?
It looks as if you omitted some of your code while you were pasting. If you are still stuck, post where you're at and I'll try and help you out.