Help for this page

Select Code to Download


  1. or download this
    $_ = qq{133.133.133.133, 87.87.87.87 127.0.0.1 - - [21/Apr/2012:04:35:
    +01 +0200] "GET /seo/vbseocp.php HTTP/1.0" 404 300 "-" "Internet Explo
    +rer 6.0" 95.95.95.95, 87.87.87.87 127.0.0.1 - - [22/Apr/2012:04:00:43
    + +0200] "GET / HTTP/1.0" 200 10211 "http://yandex.ru/yandsearch?text=
    +example.com" "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1;
    +)"};
    
    ...
    m/^(\S+)\, (\S+) (\S+) \- \- \[(\d{2})\/(\w+)\/(\d{4})\:(\d{2})\:(\d{2
    +})\:(\d{2})\+(\d{4})\] \"\S+\" (\d{3}) (\d+|-) \"(.*?)\" \"\.*?\"$/;
    
    print map { "[$_]\n" } $1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13;
    
  2. or download this
    m@^(\S+?), (\S+) (\S+) - - \[(\d{2})/(\w+)/(\d{4}):\s*(\d{2}):(\d{2}):
    +\s*(\d{2}) \+(\d{4})\] ".*?" (\d{3}) (\d+) "(.*?)" "(.*?)"@;
    #      1                                           2                  
    +3                         4            5              6   7