<h1>Bad Gateway!</h1>
<p>
The proxy server received an invalid
response from an upstream server.
</p>
<p>
If you think this is a server error, please contact
the <a href="mailto:%5bno%20address%20given%5d">webmaster</a>.
</p>
<h2>Error 502</h2>
<address>
<a href="/">ws.geonames.org</a><br />
<span>Mon Aug 3 10:12:44 2009<br />
Apache/2.2.10 (Linux/SUSE)</span>
</address>
This has been working fine in the past but has recently stopped working and I'm not sure why as no changes have been made to the PHP code for a long time. I found this message in the forums relating to the same error message: http://forum.geonames.org/gforum/posts/list/530.page but this is from a while ago and the explanation given doesn't explain why I can consistently access via my browser, but not PHP code.
Any help to get this resolved much appreciated,
Cheers,
Alex
Did you find a solution to your problem? We have recently moved the free web services to new servers. The only error message I see in the logfiles and have no explanation for is 'CharConversionException: Invalid char in port'. It could be possible that there are some encoding issues in your call.