Anyway you used to have a program named Foongrep where you could search on dutch telephonenumbers, but sadly it has been discontinued (after a legal battle) for a long time now. I came upon a site that still offers this service, so I wrote this small commandline program. I learned much from Juerd's vandale.pl, that checks words in the dutch dictionairy.
#!/usr/bin/perl -w #gettel.pl - poor man's foongrep for dutch telephone numbers use strict; use LWP::UserAgent; my $nummer; if ( $ARGV[0] ) { $nummer = $ARGV[0]; } else { Jammer_hoor(); } if ( $nummer !~ m/\b\d{3}-\d{7}\b/ ) { Jammer_hoor(); } #get page my $url = "http://zoekopnummer.ath.cx/index.php?nummer=$nummer"; my $info = LWP::UserAgent->new->request( HTTP::Request->new( GET => $url ) )->c +ontent; #no more newlines! $info =~ s/\n//g; #substitute number $nummer =~ s/-//gi; if ( $info !~ m/Naam:/g ) { print "\nNo info found on that number\n"; exit; } #filter out all the adds and links $info =~ s/$nummer//gi; $info =~ s/<.*?>//gi; $info =~ s/\.\.\..*?\.\.\.//gi; $info =~ s/\{.*?\}//gi; $info =~ s/\(.*?\)//gi; $info =~ s/table.*?://gi; $info =~ s/1\ item.*?sp\;//gi; $info =~ s/2\ item.*?sp\;//gi; $info =~ s/\s+/ /gi; #format for easy cut 'n paste $info =~ s/Telnr: /\n/g; $info =~ s/Naam: /\n/g; $info =~ s/Adres: /\n/g; $info =~ s/Plaats: /\n/g; $info =~ s/Postcode: /\n/g; $info =~ s/Fax: /\nfax: /g; print "$info"; sub Jammer_hoor { print "Usage: Specify a dutch telephone number like\ngettel.pl 020-123 +4567\n"; exit; }
In reply to Poor man's Foongrep for dutch telephonenumbers by teabag
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |