Issue
- Did you mean functionality in the Suggestion widget is not working for the custom Hindi dictionary.
Environment
- Liferay DXP 7.4
Resolution
1). Create a folder spellchecker in the tomcat directory under <TOMCAT_HOME>/webapps/ROOT/WEB-INF/classes/
2). Place hi_IN.txt(sample text file with custom hindi words) in the spellchecker folder.
3). Add the below property in portal-ext.properties
locales.enabled=en_US,hi_IN
locales=en_US,hi_IN
index.search.spell.checker.dictionary[hi_IN]=spellchecker/hi_IN.txt
index.search.spell.checker.supported.locales=en_US,hi_IN
4). Restart the portal and Reindex Spell Check indexes and notice the logs for indexing the new file hi_IN.txt
5). Configure the Suggestion widget so the threshold is enabled for "Did you mean...".
6). Change your Site Language to Hindi(hi_IN).
7). Navigate to the Home page and search for any word from the hi_IN.txt file by misplacing some characters.
Additional Information
- By default, the Liferay search page comes with a suggestion widget.