mirror of
https://github.com/pragma-/pbot.git
synced 2024-11-20 02:49:49 +01:00
google search module: decode HTML entities in result titles
This commit is contained in:
parent
cf0fead036
commit
0c9a9cccd2
@ -13,8 +13,8 @@ use warnings;
|
||||
# These are set automatically by the build/commit script
|
||||
use constant {
|
||||
BUILD_NAME => "PBot",
|
||||
BUILD_REVISION => 343,
|
||||
BUILD_DATE => "2011-12-30",
|
||||
BUILD_REVISION => 344,
|
||||
BUILD_DATE => "2012-01-05",
|
||||
};
|
||||
|
||||
1;
|
||||
|
@ -6,6 +6,7 @@ use warnings;
|
||||
use strict;
|
||||
|
||||
use Google::Search;
|
||||
use HTML::Entities;
|
||||
|
||||
my ($nick, $arguments, $matches);
|
||||
|
||||
@ -37,7 +38,7 @@ if(not $search->first) {
|
||||
|
||||
my $comma = "";
|
||||
while( my $result = $search->next) {
|
||||
print $comma, $result->titleNoFormatting, ": ", $result->uri;
|
||||
print $comma, decode_entities $result->titleNoFormatting, ": ", $result->uri;
|
||||
$comma = " -- ";
|
||||
last if --$matches <= 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user