File: ua.pl

package info (click to toggle)
libhttp-browserdetect-perl 3.41-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,220 kB
  • sloc: perl: 3,083; makefile: 2
file content (13 lines) | stat: -rw-r--r-- 393 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
use strict;
use warnings;
use feature qw( say );

use HTTP::BrowserDetect ();

my $ua = shift || die qq{Usage: perl $0 "my UA string"};
my $h  = HTTP::BrowserDetect->new($ua);

printf "robot: %s\n",       $h->robot        || q{ };
printf "robot name: %s\n",  $h->robot_name   || q{ };
printf "robot string %s\n", $h->robot_string || q{ };
printf "robot id: %s\n",    $h->robot_id     || q{ };