change_encoding function has wrong case in string comparison #51

Closed
davidgoode opened this Issue Jan 11, 2010 · 2 comments

2 participants

@davidgoode

On line ~9450, it compares $input === 'Windows-1252' && $output == 'UTF-8'. However, the relevant windows format is always returned as 'windows-1252' in lower case, so this comparison fails when it should succeed, and in fact the document fails to be parsed in my case because it can't find an encoding. The comparison should be changed to:

$input === 'windows-1252' &&...

This made it work fine in my case.

@rmccue
SimplePie member

Perhaps strtolower($input) === 'windows-1252' would be better, unless $input has already been strtolower()'d

@rmccue
SimplePie member

Use lowercase "windows-1252". Closed by e0b8bc6

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment