Just a tiny little script that takes a list of URLS, fetches them and compiles them.
Useful for checking all your pages will fit on the phone.
Useful for checking all your pages will fit on the phone.
#! /usr/bin/perl -w use strict; use LWP::Simple; use CGI::WML; foreach my $url (@ARGV) { my $wml = get($url); if ($wml) { my $wmlc = CGI::WML->wml_to_wmlc(-wml => $wml); if ($wmlc) { printf "$url => WML:%d WMLC:%d\n",length($wml),length($wmlc); } else { print "Failed to compile $url\n"; } } else { print "Failed to fetch $url\n"; } }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: WAP Compiler Test
by Anonymous Monk on Aug 23, 2008 at 15:55 UTC |
Back to
Cool Uses for Perl