in reply to preview HTML without a browser?

Sure you can do this quite easily.

Basically all you need to do is spoof a web browser. If you look at the RFC for the http 1.1 protocol you can read all about it ftp://ftp.isi.edu/in-notes/rfc2616.txt

The following is how I used telnet to get get the HTML code for the opening page of google.com.

NOTE: For any HTML over SSL you would have to do some extra work... For my example ">" denotes what is returned to me by the server. Everything else I typed in.

$telnet google.com 80 >Trying 64.233.187.99... >Connected to google.com. >Escape character is '^]'. GET http://www.google.com/ HTTP/1.1 >HTTP/1.1 200 OK >Cache-Control: private >Content-Type: text/html; charset=ISO-8859-1 >Server: GWS/2.1 >Transfer-Encoding: chunked >Date: Wed, 06 Jun 2007 21:01:48 GMT >Set-Cookie: >PREF=ID=b52be41e5ad2eb1b:TM=1181163708:LM=1181163708:S=Y +1L>Lo7leE_1XL >0KD; expires=Sun, 17-Jan-2038 19:14:07 GMT; path=/; >domain=.google.c +om >Connection: Keep-Alive ... #Here is the dump of the HTML that I don't want to paste.