Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl -w 
    use strict;
    ...
    close (OUTT);
    
    close(SOCK);
    
  2. or download this
        open (IN, "test1.dat") or die "Couldn't open file: $!\n";
        my $data = join '', (<IN>);
    ...
        map { print "'$_'\n";} split /\015\012/, $header;
        print "\n\n";
        map { print "'$_'\n";} (split /\015\012/, $body)[0..4];
    
  3. or download this
    'HTTP/1.1 200 OK'
    'Date: Tue, 12 Dec 2000 05:42:11 GMT'
    ...
    <TITLE>The Monastery Gates</TITLE>
    </HEAD>'
    '<BODY text="#000000" bgcolor="#FFFFFF" link="#000066" vlink="#333399"
    +>'