when AmphetaDesk retrieves a feed, if there are high
ASCII characters (those that generate special characters
like an e with an accent mark over it, etc) it will usually
result in a parsing error for that channel.
And this is the correct behavior. If the feed truly wants to use high
ASCII characters, then the producer of the feed needs to
knowingly change the feed's XML character set to support them.
However, smart quotes, emdashes, umlauts, etc., are not allowed
in standard/default XML encoding.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have a similar problem with one of my feeds. Here is a
workaround that suffices for me (although I do not guarantee
its applicability in all circumstances). It is for
AmphetaDesk version 0.93.1.
In AmphetaDesk::Channels::load_channel() (in Channels.pm),
add the following code immediately prior to the call to XMLin():
# Add encoding for The Register
if ($channel_filename =~ /register/i) {
$channel_xml =~ s/\?>/ encoding=\"ISO-8859-1\"\?>/;
}
My example is for a specific feed, The Register, that I know
does not include the character set encoding. You must change
the search string "register" to match a unique part of the
local filename for the feed you wish to modify, and you may
also need to change the encoding from ISO-8859-1 to
something appropriate for your feed.
The effect of this (highly imperfect) workaround is to
change the text declaration from
<?xml version="xxx"?>
to
<?xml version="xxx" encoding="ISO-8859-1"?>
Use at your own peril!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The code fragment in my previous comment is split into two
lines by the display. It should be one line, with a single
space between the "/" and the word "encoding", like so:
Logged In: YES
user_id=69804
And this is the correct behavior. If the feed truly wants to use high
ASCII characters, then the producer of the feed needs to
knowingly change the feed's XML character set to support them.
However, smart quotes, emdashes, umlauts, etc., are not allowed
in standard/default XML encoding.
Logged In: YES
user_id=810746
I have a similar problem with one of my feeds. Here is a
workaround that suffices for me (although I do not guarantee
its applicability in all circumstances). It is for
AmphetaDesk version 0.93.1.
In AmphetaDesk::Channels::load_channel() (in Channels.pm),
add the following code immediately prior to the call to XMLin():
# Add encoding for The Register
if ($channel_filename =~ /register/i) {
$channel_xml =~ s/\?>/ encoding=\&quot;ISO-8859-1\&quot;\?>/;
}
My example is for a specific feed, The Register, that I know
does not include the character set encoding. You must change
the search string "register" to match a unique part of the
local filename for the feed you wish to modify, and you may
also need to change the encoding from ISO-8859-1 to
something appropriate for your feed.
The effect of this (highly imperfect) workaround is to
change the text declaration from
<?xml version="xxx"?>
to
<?xml version="xxx" encoding="ISO-8859-1"?>
Use at your own peril!
Logged In: YES
user_id=810746
The code fragment in my previous comment is split into two
lines by the display. It should be one line, with a single
space between the "/" and the word "encoding", like so:
s/\?>/ encoding=\&quot;...\&quot;\?>/