OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



search using greek keywords

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

search using greek keywords

Postby maria » Fri Feb 15, 2008 7:55 am

Dear all,
we are trying to localize ojs (greece).We have a lot of work to do but we have a problem and we don't know how to solve it.We are not able to search using greek words and characters.We do have records in our database including greek names,keywords etc but when querying in greek, no results found.
thanks in advance,

maria
maria
 
Posts: 9
Joined: Thu Jan 17, 2008 8:50 am

Re: search using greek keywords

Postby mj » Fri Feb 15, 2008 8:25 am

Hi Maria,

There has been some discussion of search indexing issues with non-Latin characters at: http://pkp.sfu.ca/support/forum/viewtopic.php?f=8&t=2716&p=9691

Both the current OJS and OCS CVS source have been updated with the fix discussed in that thread, but the easiest step toward resolving this issue might be to apply the fix to your own installation by hand. Please also note that, when the index has been converted to UTF-8, you will still have to use Greek glyphs in your search string exactly as they appear in your records (eg. Ξανά rather than Ksana or Xana). That is, no transliteration is performed in the indexing process.

Please let us know if this fix addresses your problem, and if it persists, we'll continue to try to help.

Regards,
mj
Site Admin
 
Posts: 304
Joined: Fri Mar 26, 2004 9:32 am
Location: Toronto, Canada

Re: search using greek keywords

Postby maria » Fri Feb 15, 2008 8:57 am

Sorry, problem persists.

I checked config.inc.php and it is:
; Default locale
locale = en_US
client_charset = utf-8
connection_charset = utf8
database_charset = utf8
charset_normalization = on

I don't expect to query for "xsana" when my record is "ξανα" .. I tried to query the exact words as they appear in my db records.. I don't get an error .I just don' t get results..

mj wrote:Hi Maria,

There has been some discussion of search indexing issues with non-Latin characters at: http://pkp.sfu.ca/support/forum/viewtopic.php?f=8&t=2716&p=9691

Both the current OJS and OCS CVS source have been updated with the fix discussed in that thread, but the easiest step toward resolving this issue might be to apply the fix to your own installation by hand. Please also note that, when the index has been converted to UTF-8, you will still have to use Greek glyphs in your search string exactly as they appear in your records (eg. Ξανά rather than Ksana or Xana). That is, no transliteration is performed in the indexing process.

Please let us know if this fix addresses your problem, and if it persists, we'll continue to try to help.

Regards,
maria
 
Posts: 9
Joined: Thu Jan 17, 2008 8:50 am

Re: search using greek keywords

Postby mj » Fri Feb 15, 2008 9:49 am

Hi Maria,

Did you apply the fix as described in the other post thread? Namely, change: classes/search/ArticleSearchIndex.inc.php, line 114

from:
Code: Select all
      $cleanText = String::regexp_replace('/[!"\#\$%\'\(\)\.\?@\[\]\^`\{\}~]/', '', $cleanText);


to:
Code: Select all
      $cleanText = Core::cleanVar($text);
      $cleanText = String::regexp_replace('/[!"\#\$%\'\(\)\.\?@\[\]\^`\{\}~]/', '', $cleanText);


You will have to do this, followed by manually re-indexing your journal by running the tools/rebuildSearchIndex.php script, in order to update the search index to support Greek characters through UTF-8.
mj
Site Admin
 
Posts: 304
Joined: Fri Mar 26, 2004 9:32 am
Location: Toronto, Canada

Re: search using greek keywords

Postby maria » Mon Feb 18, 2008 1:09 am

i did apply the following changes and ran the tools/rebuildSearchIndex.php script but nothing changed..
could it be something else? windows xp???

mj wrote:Hi Maria,

Did you apply the fix as described in the other post thread? Namely, change: classes/search/ArticleSearchIndex.inc.php, line 114

from:
Code: Select all
      $cleanText = String::regexp_replace('/[!"\#\$%\'\(\)\.\?@\[\]\^`\{\}~]/', '', $cleanText);


to:
Code: Select all
      $cleanText = Core::cleanVar($text);
      $cleanText = String::regexp_replace('/[!"\#\$%\'\(\)\.\?@\[\]\^`\{\}~]/', '', $cleanText);


You will have to do this, followed by manually re-indexing your journal by running the tools/rebuildSearchIndex.php script, in order to update the search index to support Greek characters through UTF-8.
maria
 
Posts: 9
Joined: Thu Jan 17, 2008 8:50 am

Re: search using greek keywords

Postby rania » Mon Mar 03, 2008 2:18 am

Geia sou Maria! :D

I 'm sorry for the delay but I had some health problems and have been out of the work for the past month.
Did you fix the problem?
I had no problem searching in greek both in OJS 2.1.1 and 2.2 installed in linux and Windows XP.
I would suggest to check the DB configuration in MySQL. It may be in latin (default) and not UTF8, that causes some problems with OJS and greek as I have noticed!

Ta leme!

Rania
rania
 
Posts: 35
Joined: Thu Nov 08, 2007 1:37 am


Return to OJS Technical Support

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 8 guests