Webboard: Reading ISpell files failes
| Newsgroups | gmane.comp.web.mnogosearch.general |
|---|---|
| Message-ID | <[email protected]> |
Author: Illenberger
Email:
Message:
Version 3.3.9 code has to be changed from
[PHP]
$temp= $spell_file[$t_lang];
for ($i=0; $i<count($temp); $i++)
{
if (!
Udm_Load_Ispell_Data($udm_agent,UDM_ISPELL_TYPE_SPELL,$t_l
ang,$temp[$i],1))
{
print_error_local("Error loading ispell data from file");
}
else
$have_spell_flag=1;
}
[/PHP]
to the 3.2.11 code:
[PHP]
$temp= $spell_file[$t_lang];
for ($i=0; $i<count($temp); $i++)
{
if (preg_match("/(.+)\;(.+)/",$temp[$i],$param)) {
$t_charset=trim($param[1]);
$t_file=trim($param[2]);
if (!
Udm_Load_Ispell_Data($udm_agent,UDM_ISPELL_TYPE_SPELL,$t_l
ang,$t_charset,$t_file,1)) {
print_error_local("Error loading ispell data from file");
}
else
$have_spell_flag=1;
}
}
[/PHP]
Thereafter dict files are loaded correctly.
Reply: <http://www.mnogosearch.org/board/message.php?id=21078>