Is there ways to add words to the spell check, I run ihatedialysis.com and we use a lot of medical terminology and it get's old always having to hit ignore.
Thanks for the help.
- Epoman
Hi,
Look in Sources/Subs-Post.php and find
function SpellCheck()
{
global $txt, $context;
// A list of "words" we know about but pspell doesn't.
$known_words = array('smf', 'php', 'mysql', 'www', 'gif', 'jpeg', 'png', 'http', 'smfisawesome', 'grandia', 'terranigma', 'rpgs');
Just add your words to the list using the same format :)
Quote from: Fizzy on June 26, 2006, 02:48:25 AM
Hi,
Look in Sources/Subs-Post.php and find
function SpellCheck()
{
global $txt, $context;
// A list of "words" we know about but pspell doesn't.
$known_words = array('smf', 'php', 'mysql', 'www', 'gif', 'jpeg', 'png', 'http', 'smfisawesome', 'grandia', 'terranigma', 'rpgs');
Just add your words to the list using the same formatĀ :)
Wow it can't be THAT easy :o :) I'll go try right now, thank you very much.
- Epoman
Wow that was too easy, thank you very much for the help. By the way, is there a limit of the number of words I can add?
- Epoman
There's no reason for there to be a limit. After all, it's just an array.
Quote from: Sol on June 26, 2006, 03:36:15 AM
There's no reason for there to be a limit. After all, it's just an array.
Thanks. ;) I'm still learning all of this stuff. You guys are great!
- Epoman
some spell checks off the option to "learn", how
can we get this in SMF.
Quote from: Epoman on June 26, 2006, 03:22:43 AM
Wow that was too easy, thank you very much for the help. By the way, is there a limit of the number of words I can add?
- Epoman
Hey, you're welcome :) and no, there isn't any limit to the number of additions :)
Hi Guys,
I tried adding words as instructed, but still they are not accepted. Furthermore the spellcheck places the proposed word at the 'replace' box, not the word it thinks is wrong (and suggest the same).
See http://7summits.com/forum
test acount: user: smftest, pw smftest
try with "Denali", or "Kili", 2 words used a lot.
Thanks for any pointers,
Cheers,
7s
Hi 7s
Can you please post how you added the content below the line "function SpellCheck()"
Hi Fizzy,
here it is:
function SpellCheck()
{
global $txt, $context;
// A list of "words" we know about but pspell doesn't.
$known_words = array('smf', 'php', 'mysql', 'www', 'http', 'Everest', 'Denali', 'Kili', 'Vinson', 'McKinley', 'Elbrus', 'Kilimanjaro', 'Carstensz', 'Kosciuszko', 'Aconcagua');
loadTemplate('Post');
loadLanguage('Post');
Hi 7,
Can you try changing the summit names to lower case only please
Hi, yes, changing to lowercase helps in the way that it does not question the words anymore, thanks.
So, two smaller problems remain, not sure if they can be solved:
(1) The added words are not used in the suggestion list (for example when somebody types Denaali, it will not suggest Denali in the list). Is there a way to have the added words be added to teh dictionary as well and not just ignored?
(2) Somehow the word in the 'change' box is not the word that was spelled wrong, but it is the first word in the 'suggestions' list, so you cannot see which word will be changed. Is this normal?
Thanks for any help,
best regards,
7s
Hi 7,
The answer to (1) is that I think you would have to get your host to add the words in to the dictionary for it to work like that. The Subs list is just a way of overlooking certain words.
The answer to (2) ... hmmm a bit trickier. I went to try and see an example using the login details you provided but unfortunately I got a template parse error.
Hi Fizzy, the template error should be gone now, sorry for that..
Hi 7,
Thanks for that.
If I had to hazard a guess I would say that the problem may be related to the javascript you have running on your forum or the fact that the default theme is not functioning corectly.
Can you try correcting the template errors in the default theme and see if that help correct the problem with spellcheck.