95 |
$s=~tr/¹©ðÐèÈæƾ®/sSdDcCcCzZ/; |
$s=~tr/¹©ðÐèÈæƾ®/sSdDcCcCzZ/; |
96 |
$s=~s/\*\*+/*/g; |
$s=~s/\*\*+/*/g; |
97 |
|
|
98 |
|
my @properties = split(/\s+/,x($config->{properties})); |
99 |
|
|
100 |
my $sh = SWISH->connect('Fork', |
my $sh = SWISH->connect('Fork', |
101 |
prog => x($config->{prog}), |
prog => x($config->{prog}), |
102 |
indexes => x($config->{index}), |
indexes => x($config->{index}), |
103 |
# properties => [qw/god br nr/], |
properties => \@properties, |
104 |
results => sub { |
results => sub { |
105 |
my ($sh,$hit) = @_; |
my ($sh,$hit) = @_; |
106 |
|
|
107 |
|
my $hit_fmt = x($config->{hit}) || |
108 |
|
"<a href=\"%s\">%s</a> [%s]<br>\n"; |
109 |
|
|
110 |
if ($config->{url}) { |
if ($config->{url}) { |
111 |
printf ("<a href=\"%s\">%s</a> [%s]<br>\n","http://".virtual_host().x($config->{url}).$hit->swishdocpath,$hit->swishtitle || 'untitled',$hit->swishrank); |
printf ($hit_fmt ,"http://".virtual_host().x($config->{url}).$hit->swishdocpath,$hit->swishtitle || 'untitled',$hit->swishrank); |
112 |
} else { |
} else { |
113 |
printf ("<a href=\"%s\">%s</a> [%s]<br>\n",$hit->swishdocpath,$hit->swishtitle || 'untitled',$hit->swishrank); |
printf ($hit_fmt ,$hit->swishdocpath,$hit->swishtitle || 'untitled',$hit->swishrank, map($hit->$_, @properties) ); |
114 |
|
|
115 |
} |
} |
116 |
|
|