reducing size of setup.php
[squirrelmail.git] / plugins / squirrelspell / sqspell_config.php
CommitLineData
849bdf42 1<?php
d112ed5a 2/**
3 * sqspell_config.php -- SquirrelSpell Configuration file.
4 *
6c84ba1e 5 * Copyright (c) 1999-2005 The SquirrelMail Project Team
d112ed5a 6 * Licensed under the GNU GPL. For full terms see the file COPYING.
7 *
7996c920 8 * @version $Id$
ea5f4b8e 9 * @package plugins
10 * @subpackage squirrelspell
d112ed5a 11 */
849bdf42 12
7996c920 13/** @ignore */
14if (! defined('SM_PATH')) define('SM_PATH','../../');
3392dc86 15
7996c920 16/** getHashedFile() function for SQSPELL_WORDS_FILE and sqgetGlobalVar() from global.php */
17include_once(SM_PATH . 'functions/prefs.php');
8a9f9d09 18
7996c920 19/** vars needed for getHashedFile() */
20global $data_dir;
b587ac51 21sqgetGlobalVar('username', $username, SQ_SESSION);
849bdf42 22
d112ed5a 23/**
7996c920 24 * List of configured dictionaries
25 *
26 * This feature was added/changed in 0.3. Use this array to set up
27 * which dictionaries are available to users. If you only have
28 * English spellchecker on your system, then let this line be:
29 *<pre>
30 * $SQSPELL_APP = array('English' => 'ispell -a');
31 * or
32 * $SQSPELL_APP = array('English' => '/usr/local/bin/aspell -a');
33 *</pre>
34 * Sometimes you have to specify full path for PHP to find it.
35 *
36 * You can use Aspell or Ispell spellcheckers. Aspell might provide
37 * better spellchecking for Western languages.
38 *
39 * If you want to have more than one dictionary available to users,
40 * configure the array to look something like this:
41 *<pre>
42 * $SQSPELL_APP = array('English' => 'aspell -a',
43 * 'Russian' => 'ispell -d russian -a',
44 * ...
45 * 'Swahili' => 'ispell -d swahili -a'
46 * );
47 *</pre>
48 * WARNINGS:
49 * <ul>
50 * <li>Watch the commas, making sure there isn't one after your last
51 * dictionary declaration. Also, make sure all these dictionaries
52 * are available on your system before you specify them here.</li>
53 * <li>Whatever your setting is, don't omit the "-a" flag.</li>
54 * <li>Remember to keep same array keys during upgrades. Don't rename them.
55 * Users' dictionary settings use it.</li>
56 * <li>Interface might translate array key, if used key is present in
57 * SquirrelMail translations.</li>
58 * </ul>
59 * <pre>
d112ed5a 60 * Example:
7996c920 61 * $SQSPELL_APP = array('English' => 'ispell -a',
62 * 'Spanish' => 'ispell -d spanish -a' );
63 * </pre>
d112ed5a 64 *
7996c920 65 * @global array $SQSPELL_APP
d112ed5a 66 */
2a917bbc 67$SQSPELL_APP = array('English' => 'ispell -a',
7996c920 68 'Spanish' => 'ispell -d spanish -a');
69
70/**
71 * Default dictionary
72 * @global string $SQSPELL_APP_DEFAULT
73 */
d112ed5a 74$SQSPELL_APP_DEFAULT = 'English';
7996c920 75
76/**
77 * File that stores user's dictionary
78 *
79 * $SQSPELL_WORDS_FILE is a location and mask of a user dictionary file.
80 * The default setting should be OK for most everyone.
81 *
82 * This setting is used only when SquirrelSpell is upgraded from
83 * older setup. Since SquirrelMail 1.5.1 SquirrelSpell stores all settings in
84 * same place that stores other SquirrelMail user preferences.
85 * @global string $SQSPELL_WORDS_FILE
86 * @deprecated setting is still needed in order to handle upgrades
87 */
91e0dccc 88$SQSPELL_WORDS_FILE =
d112ed5a 89 getHashedFile($username, $data_dir, "$username.words");
849bdf42 90
7996c920 91/**
e5af0839 92 * Function used for checking words in user's dictionary
7996c920 93 * @global string $SQSPELL_EREG
94 * @deprecated It is not used since 1.5.1 (sqspell 0.5)
95 */
d112ed5a 96$SQSPELL_EREG = 'ereg';
849bdf42 97
91e0dccc 98?>