GunghoX::FollowLinks::Rule::MIME - Follow Based On MIME Type
use GunghoX::FollowLinks::Rule::MIME; # Allow matched, deny unmatched, defer unknown my $rule = GunghoX::FollowLinks::Rule::MIME->new( types => [ qw(text/html text/plain) ] ); # Deny unmatched, but allow if unknown my $rule = GunghoX::FollowLinks::Rule::MIME->new( unknown => FOLLOW_ALLOW, types => [ qw(text/html) ] ); # Only allow matched (deny unmatched, deny unknown) my $rule = GunghoX::FollowLinks::Rule::MIME->new( unknown => FOLLOW_DENY, types => [ qw(text/html) ] );
Rule::MIME allows you to use the file name extensions to guess the MIME type of a link, and decided to follow or not based on the type
To install GunghoX::FollowLinks, copy and paste the appropriate command in to your terminal.
cpanm
cpanm GunghoX::FollowLinks
CPAN shell
perl -MCPAN -e shell install GunghoX::FollowLinks
For more information on module installation, please visit the detailed CPAN module installation guide.