Use correct term prefixes when searching.

The Z term prefix is for stemming and shouldn't be used here.
X is for custom fields.
master
Gabriel McManus 2008-07-17 20:37:08 +10:00 committed by Joey Hess
parent c7b400af42
commit e3b0584a49
2 changed files with 3 additions and 3 deletions

View File

@ -123,9 +123,9 @@ sub index (@) { #{{{
$tg->index_text($caption, 2); $tg->index_text($caption, 2);
$tg->index_text($title, 2) if $title ne $caption; $tg->index_text($title, 2) if $title ne $caption;
$tg->index_text($toindex); $tg->index_text($toindex);
$tg->index_text(lc($title), 1, "ZS"); # for title:foo $tg->index_text(lc($title), 1, "S"); # for title:foo
foreach my $link (@{$links{$params{page}}}) { foreach my $link (@{$links{$params{page}}}) {
$tg->index_text(lc($link), 1, "ZLINK"); # for link:bar $tg->index_text(lc($link), 1, "XLINK"); # for link:bar
} }
$doc->add_term($pageterm); $doc->add_term($pageterm);

View File

@ -1,5 +1,5 @@
$setmap{prefix,title,S} $setmap{prefix,title,S}
$setmap{prefix,link,LINK} $setmap{prefix,link,XLINK}
$set{thousand,$.}$set{decimal,.}$setmap{BN,,Any Country,uk,England,fr,France} $set{thousand,$.}$set{decimal,.}$setmap{BN,,Any Country,uk,England,fr,France}
${ ${
$def{PREV, $def{PREV,