4 ** INIT.MOD.PHP -- Squirrelspell module
6 ** Copyright (c) 1999-2002 The SquirrelMail development team
7 ** Licensed under the GNU GPL. For full terms see the file COPYING.
9 ** Initial loading of the popup window interface.
14 // See if we need to give user the option of choosing which dictionary
15 // he wants to use to spellcheck his message.
16 $langs=sqspell_getSettings(null);
17 $msg = '<form method="post">'.
18 '<input type="hidden" name="MOD" value="check_me">'.
19 '<input type="hidden" name="sqspell_text">'.
21 if (sizeof($langs)==1){
22 // only one dictionary defined by the users. Submit the form
24 $onload="sqspell_init(true)";
25 $msg .= _("Please wait, communicating with the server...") .
27 "<input type=\"hidden\" name=\"sqspell_use_app\" value=\"$langs[0]\">";
29 // more than one dictionary. Let the user choose the dictionary first
30 // then manually submit the form.
31 $onload="sqspell_init(false)";
32 $msg .= _("Please choose which dictionary you would like to use to spellcheck this message:").
33 '</p><p align="center">' .
34 '<select name="sqspell_use_app">';
35 for ($i=0; $i<sizeof($langs); $i++){
40 $msg .= " value=\"$langs[$i]\"> " . _($langs[$i]) . "</option>\n";
44 '<input type="submit" value="' . _("Go") . '">'.
48 sqspell_makeWindow($onload, _("SquirrelSpell Initiating"), "init.js", $msg);