Path: news1.icaen!news.uiowa.edu!chi-news.cic.net!arclight.uoregon.edu!enews.sgi.com!news.idt.net!cam-news-hub1.bbnplanet.com!cpk-news-hub1.bbnplanet.com!news.bbnplanet.com!uunet!in3.uu.net!129.59.1.25!news.vanderbilt.edu!NO%lesh%SPAM%erjt%HERE From: NO%lesh%SPAM%erjt%HERE@vuse.vanderbilt.edu (Tilghman Lesher) Newsgroups: comp.sys.apple2 Subject: Spectrum Internet Suite technique Date: 21 Apr 1997 09:36:24 GMT Organization: Vanderbilt University School of Engineering, Nashville, TN, USA Lines: 52 Message-ID: <5jfceo$98s$2@news.vanderbilt.edu> NNTP-Posting-Host: goliath.vuse.vanderbilt.edu X-Newsreader: TIN [version 1.2 PL2] I believe I've finally figured a full script using ONLY standard UNIX utilities which will do the same thing as SIS. Posted purely FYI, you need SIS for the html parsing, which this doesn't provide. Since this was posted before I even touched SIS or any of its documentation, you can be sure no reverse engineering was done. By the way, this will NOT work as a shell script. You'd need expect to do that, and expect is not available on all UNIX systems. Each command can be typed from the command line, however. # 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 GET $request # This part is only necessary if the output was bin (e.g. jpg)... # It gets rid of some initial stuff which is not actually part # of the request. 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 # 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 -- __ __|_) | | | | | _` | \ ` \ _` | \ _| _|_|\__, |_| _|_|_|_|\__,_|_| _| ____/