javascript - How do I handle this response from YQL -
in request yql (select * html url="...")
got following response:
callback({ "query": {"count":"1","created":"2011-05-09t23:29:05z","lang":"en-us" }, "results": ["<body>... we\ufffdll call mr ...</body>"] }
this yql console page. when type sequence firebug (even on yql's page) get:
... we�ll call mr ...
what doing wrong? yql's site in bad encoding? there way convert symbols ascii equivalent?
btw isn't site it's not can change meta charset on site
it seems (the question mark in solid black diamond) should seeing: http://www.fileformat.info/info/unicode/char/fffd/browsertest.htm
the comment on character's page says:
used replace incoming character value unknown or unrepresentable in unicode
maybe answers these might better answer:
- what character expecting @ place?
- can post url you're scraping?
- is character on page or getting mangled when picked yql?
update
you might want check out charset
option in where
clause of yql query - i'm not entirely sure looks forces yql engine use specified charset when parsing page. perhaps setting utf-8
solve problem.
for example,
select * html url = 'http://google.com' , charset='utf-8'
Comments
Post a Comment