/[Semantic-Engine]/EPrints/index.pl
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /EPrints/index.pl

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3 by dpavlin, Fri Jun 29 09:21:11 2007 UTC revision 4 by dpavlin, Fri Jun 29 09:52:53 2007 UTC
# Line 11  warn dump( StemHR->stem('kuŠni') ); Line 11  warn dump( StemHR->stem('kuŠni') );
11    
12  my $debug = shift @ARGV;  my $debug = shift @ARGV;
13    
14    my $type = 'slogovi';
15    
16  my $dbh = EPrints->dbh;  my $dbh = EPrints->dbh;
17  my $sth = $dbh->prepare(qq{  my $sth = $dbh->prepare(qq{
18  SELECT  SELECT
# Line 32  $indexer->add_word_filters( minimum_leng Line 34  $indexer->add_word_filters( minimum_leng
34                              maximum_word_length => 15 );                              maximum_word_length => 15 );
35    
36  # use this encoding for any incoming text  # use this encoding for any incoming text
37  $indexer->set_default_encoding( "utf8");  #$indexer->set_default_encoding( "utf8");
38    
39  my $total = 0;  my $total = 0;
40    
# Line 46  while (my $row = $sth->fetchrow_hashref Line 48  while (my $row = $sth->fetchrow_hashref
48          my @body = split( /\W*\s+\W*/, "$title $title $title $keywords $keywords $abstract" );          my @body = split( /\W*\s+\W*/, "$title $title $title $keywords $keywords $abstract" );
49          my $body;          my $body;
50          foreach my $word ( @body ) {          foreach my $word ( @body ) {
51                  $body .= StemHR->stem( $word ) . ' ';  #               $body .= StemHR->stem( $word ) . ' ';
52                    $body .= join(" ",EPrints::slogovi( $word )) . ' ';
53          }          }
54    
55          warn "body: $body\n" if $debug;          warn "body: $body\n" if $debug;

Legend:
Removed from v.3  
changed lines
  Added in v.4

  ViewVC Help
Powered by ViewVC 1.1.26