(Ethernet) webclient

I want to read the local weather data (hong kong) for Arduino programming needs.
It seems to be a good start to base on sample WebClient code.

for http://www.hko.gov.hk/textonly/forecast/englishwx2.htm, it is supposedly easy.
i.e.
byte server[] = { 210, 0, 235, 4 } as www.hko.gov.hk
and ("GET /textonly/forecast/englishwx2.html HTTP/1.0");

Unlike at least 5 other sites, this (210, 0, 235, 4) site simply refuses to give any text after 'connected'. Is it a special nature of this website that made the client.read() fail ??

note: http://210.0.235.4/textonly/forecast/englishwx2.htm is perfect with a browser.

thanks for suggestion.
-Frankie.

Maybe there is something in your undisclosed code.

That's why:

telnet 210.0.235.4 80
Trying 210.0.235.4...
Connected to 210.0.235.4.
Escape character is '^]'.
GET /textonly/forecast/englishwx2.htm HTTP/1.0

HTTP/1.1 404 Not found
Server: Zeus/4.3
Date: Mon, 04 Jun 2012 15:02:30 GMT
Connection: close
Content-Type: text/html
Via: CN-5000

<html><head><title>Error 404 Not found
</title></head><body bgcolor=#ffffff><h2>Error 404 Not found
</h2><p>The host name in the URL you have requested does not match any virtual server currently running. This may be because you entered the host name incorrectly, or because the necessary server alias has not been set up.<p><i>Powered by <a href="http://errors.zeus.com/">Zeus Technology</a></i></body></html>
Connection closed by foreign host.

This host (or the firewall in front of it) is a little picky and does not allow minimal HTTP headers. You probably have to do some trial and error to find out which headers from the many a standard browser sends by default you have to supply to get the page.

It was quite easy, you just have to supply a host to it:

telnet 210.0.235.4 80
Trying 210.0.235.4...
Connected to 210.0.235.4.
Escape character is '^]'.
GET /textonly/forecast/englishwx2.htm HTTP/1.0
Host: 210.0.235.4

HTTP/1.1 200 OK
Server: Zeus/4.3
Date: Mon, 04 Jun 2012 15:07:17 GMT
Content-Length: 2752
Accept-Ranges: bytes
Content-Type: text/html
Last-Modified: Mon, 04 Jun 2012 15:02:48 GMT
_onnection: Keep-Alive
Via: CN-5000
Connection: close

<HTML>
<HEAD>
<TITLE>Current Weather</TITLE>
<META http-equiv="Content-Type" content="text/html; CHARSET=Big5-HKSCS">
<meta name="Comments" content="WCAG2_0_Verified" />
<meta name="Page Description" content="Current Weather" />
<meta name="Page Keywords" content="Current Weather" />

</HEAD>
<BODY  bgcolor="#FFFFFF">
<script type="text/javascript" src="/js/jquery/jquery-1.6.4.min.js"></script>
<script type="text/javascript" src="/js/clf_textonly.js"></script>
<style type="text/css">
#wcag_logo_area{
	display:inline;
	text-align: center;
}
#wcag_logo_area a img{
	border:	0px;
	position:relative;
	top:12px;
}
</style>
<link rel="SHORTCUT ICON" href="/Logo.ico">
<p align="center"><img src="../../images_e/logo_dblue.gif" alt="Hong Kong Observatory Logo" width="333" height="65"></p>
<div style="font-weight:bold; font-size:200%; text-align:center;">Current Weather</div><p>
<span style="font-style:italic;">Bulletin updated at 23:02 HKT 04/Jun/2012</span>
</p>
<!--Current Weather-->
<pre>
At 11 p.m. at Hong Kong Observatory :
Air Temperature : 27 degrees Celsius
Relative Humidity : 85 per cent
Weather Cartoon : No. 76 - MAINLY CLOUDY 


The air temperatures at other places were:

King's Park                     26 degrees;
Wong Chuk Hang                  25 degrees;
Ta Kwu Ling                     26 degrees;
Lau Fau Shan                    27 degrees;
Tai Po                          26 degrees;
Sha Tin                         25 degrees;
Tuen Mun                        27 degrees;
Tseung Kwan O                   25 degrees;
Sai Kung                        26 degrees;
Cheung Chau                     25 degrees;
Chek Lap Kok                    28 degrees;
Tsing Yi                        26 degrees;
Shek Kong                       26 degrees;
Tsuen Wan Ho Koon               25 degrees;
Tsuen Wan Shing Mun Valley      25 degrees;
Hong Kong Park                  26 degrees;
Shau Kei Wan                    25 degrees;
Kowloon City                    26 degrees;
Happy Valley                    26 degrees;
Wong Tai Sin                    26 degrees;
Stanley                         26 degrees;
Kwun Tong                       26 degrees;
Sham Shui Po                    27 degrees.

</pre>
<!--/Current Weather-->
<hr>
| <a href="../readme.htm">Copyright and Disclaimer</a> | <a href="../index.htm">Home</a> | 
<a href="chinesewx2.htm">Chinese Version / ??????</a> | <a href="http://rss.weather.gov.hk/rss/CurrentWeather.xml"><img src="/img/rss3.gif" alt="Current Weather Report RSS" border="0"/></a> | 
<div id="wcag_logo_area"></div>
<link rel="alternate" type="application/rss+xml" title="Current Weather Report" href="http://rss.weather.gov.hk/rss/CurrentWeather.xml">
</BODY>
</HTML>