Re: [greenstone-devel] character mapping in index building [SOLVED]

From jens wille
DateMon, 15 Aug 2005 16:01:17 +0200
Subject Re: [greenstone-devel] character mapping in index building [SOLVED]
In-Reply-To (42FFF18F-3010605-cs-waikato-ac-nz)
hi katherine!

thank you so much! it works :-)

two remarks (for browsing lists):
- i had to substitute both ascii and utf8 occurences of my
characters (actually only utf8, but to be on the safe side... ;-)
- it had to happen before the format_string_* subroutines were
called (otherwise the utf8 representations were broken)


Katherine Don wrote:
> You will need to make a change in two places:
> For searching, add it to filter_text in mgbuildproc, but only do it if
> you are indexing. Depending on which version on greenstone you are
> using, you could add filter_text to basebuildproc, and remove the empty
> ones from mg/mgppbuildprocs, then all build types can use it.
> eg
> sub filter_text {
> my $self = shift (@_);
> my ($field, $text) = @_;
> if ($self->{'indexing_text'} ) {
> &sorttools::filter_characters($text);
> }
> }
> In, implement your filter_characters($text);
> For browsing, add it to format_metadata_for_sorting in
> This should be called on all metadata used for sorting in classifiers.