[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: WWW browser for gs.os??????



Joseph Klein Annapolis (jjklein@clark.net) wrote:
: Tilghman Lesher <NO%lesh%SPAM%erjt%HERE@vuse.vanderbilt.edu> wrote:

: >I showed a nice little method where this would be possible.  (Check

: Your method does not allow for downloading of binary graphics.  Paul
: is 100% correct to the fact that TCP/IP is need for binary FTP
: and/or downloading binary graphics from a web site.

: Geoff Weiss

Reread it.  It most certainly DOES allow sending of binary graphics,
mainly because it uses uuencode to change 8-bit data into 7-bit text.

I have TESTED the bloody thing, and it most certainly DOES work.


# This is the URL...
set request=http://www.vuse.vanderbilt.edu/

# This is the host which was extracted from the URL...
set host=www.vuse.vanderbilt.edu

# This is the default port for www, overridden if specified in the URL...
set port=80

# tee is used to make sure we get the output (dunno if necessary or not)...
telnet $host $port | tee /tmp/telnet.file > /dev/null 
echo GET $request

#     LOOK RIGHT HERE, GEOFF
#     THIS IS THE PART, GEOFF

# This part is only necessary if the output was bin (e.g. jpg)...
set preprelen=`wc -l /tmp/telnet.file`
set prelen=$preprelen[1]
set len=`expr $prelen - 3`
tail -$len /tmp/telnet.file | uuencode telnet.file > /tmp/telnet.uue   

#     DON'T FORGET TO LOOK RIGHT ABOVE HERE, GEOFF

# We may want to use 'sz' for a reliable xfer... otherwise, we
# may need to 'split' the file up into chunks, and 'cat' each
# one separately to stdout (us).  'split' is only necessary if
# the file is above a certain size. 


# This part is VERY important.
rm /tmp/telnet.file /tmp/telnet.uue


--
__ __|_) |       |                    
   |   | |  _` |   \   ` \   _` |   \ 
  _|  _|_|\__, |_| _|_|_|_|\__,_|_| _|
          ____/