ID: 40759
User updated by: david at mytton dot net
-Summary: pspell_new_personsal does not load custom dictionary
Reported By: david at mytton dot net
Status: Open
Bug Type: Pspell related
Operating System: Windows XP
PHP Version: 5.2.1
New Comment:

Corrected typo in summary


Previous Comments:
------------------------------------------------------------------------

[2007-03-08 17:13:40] david at mytton dot net

Description:
------------
The personal dictionary does not appear to be used when asking pspell
for suggestions.

The same result occurs whether or not custom.dict actually exists. E.g.
if I change the filename to customdict no error is output and the output
is the same.

I tried this with the latest php_pspell.dll from
[url]http://snaps.php.net/win32/php5.2-win32-200703081530.zip[/url]

Reproduce code:
---------------
<?php
$spelling = pspell_new_personal('C:\Program Files\Apache Software
Foundation\Apache2.2\htdocs\custom.dict', 'en');
$suggestions = pspell_suggest($spelling, 'bloomsbur');
echo '<pre>'; print_r($suggestions); '</pre>';
?>

custom.dict:

personal_ws-1.1 en 1
bloomsbury

Expected result:
----------------
Array of suggestions including bloomsbury in the suggestions.

Actual result:
--------------
bloomsbury is not in the suggestions list:

Array
(
[0] => blooms bur
[1] => blooms-bur
[2] => blooms
[3] => Bloom's
[4] => bloom's
[5] => bloomers
[6] => Bloomer
[7] => bloomer
)


------------------------------------------------------------------------


--
Edit this bug report at [url]http://bugs.php.net/?id=40759&edit=1[/url]