wrote:
> Perhaps someone knows the answer to this problem. I open a connection
> to a URL and read lines one at a time from the URL using a
> InputStreamReader and a BufferedReader:
[...]
> However, the actual text I get back from the URL is different from that
> saved out of a browser from the same URL. Particularly, the browser
> saves £ characters, whereas the lines read in Java are missing
> these characters altogether. Also, some of the characters have actually
> been deleted in the Java lines.
Maybe the website is using something like the Accept-Language: field in the
request to decide what currency (etc) to send back. I don't know what the Java
HTTP client will send in that field by default, but it is unlikely to be
'en-GB' which is what my browser would send.
I just tried it myself, but -- most unfortunately -- the site has just stopped
responding. I /do/ hope my little experiment didn't kill it...
-- chris