Changes between Initial Version and Version 1 of Ticket #9518, comment 8


Ignore:
Timestamp:
Aug 28, 2013, 9:10:00 AM (7 years ago)
Author:
Scott González
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #9518, comment 8

    initial v1  
    1 Thanks, that explains it. So here's the problem: The ISO-8859-1 page will generate a URL that is encoded using ISO-8859-1. However, `decodeURIComponent()` ALWAYS uses UTF-8 for the character set. I honestly don't think this is something we can properly fix. My only thought is that we can wrap the decoding in a try/catch and just accept the fact that are some situations we can't handle. Perhaps when Safari 5.1 dies out we can just remove the encoding, but we'll need to verify that #8896 is actually limited to spaces in other browsers.
     1Thanks, that explains it. So here's the problem: The ISO-8859-1 page will generate a URL that is encoded using ISO-8859-1. However, `decodeURIComponent()` ALWAYS uses UTF-8 for the character set. I honestly don't think this is something we can properly fix. My only thought is that we can wrap the decoding in a try/catch and just accept the fact that there are some situations we can't handle. Perhaps when Safari 5.1 dies out we can just remove the encoding, but we'll need to verify that #8896 is actually limited to spaces in other browsers.