inclusive-design / AChecker

Automated interactive Web content accessibility checker.
https://achecker.ca
GNU General Public License v2.0
69 stars 61 forks source link

Fix encoding error when call REST API for the pages including local characters except English #41

Closed blurblah closed 10 years ago

blurblah commented 10 years ago

I changed encoding ISO-8859-1 to UTF-8 for XML generation. In case of including some local characters (in html_code), those characters are not changed properly because of ISO-8859-1 encoding when generate XML.

So we should use UTF-8 instead of ISO-8859-1. As we know, AChecker already uses UTF-8 encoding for HTML output.

cindyli commented 10 years ago

Please update the corresponding documentation for REST encoding: https://github.com/atutor/AChecker/blob/master/documentation/web_service_api.php#L325

Thanks for the contribution. We appreciate it.

blurblah commented 10 years ago

I removed ENT_IGNORE flag and tested it on some pages. And modified corresponding documentation, too.

While testing some pages (please check test.com using REST), I met undefined ndash entity error. So added ndash entity in RESTWebServiceOutput.class.php.

Please check my commit and add comment if you want.

cindyli commented 10 years ago

Thanks for the beautiful work, @blurblah.