X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=plugins%2Fsquirrelspell%2Fsqspell_config.php;h=1a55f2fe96a5d3660dc2d0bd7a9a27cf57b641b2;hb=22387c8d44f3ab104db6e19180d3775a45762359;hp=ff139b5deb22c63b86d2e1619ff642bbf1211454;hpb=47ccfad452e8d345542d09e59112cac317cffed8;p=squirrelmail.git diff --git a/plugins/squirrelspell/sqspell_config.php b/plugins/squirrelspell/sqspell_config.php index ff139b5d..1a55f2fe 100644 --- a/plugins/squirrelspell/sqspell_config.php +++ b/plugins/squirrelspell/sqspell_config.php @@ -3,19 +3,13 @@ /** * sqspell_config.php -- SquirrelSpell Configuration file. * - * @copyright © 1999-2006 The SquirrelMail Project Team + * @copyright 1999-2017 The SquirrelMail Project Team * @license http://opensource.org/licenses/gpl-license.php GNU Public License * @version $Id$ * @package plugins * @subpackage squirrelspell */ -/** @ignore */ -if (! defined('SM_PATH')) define('SM_PATH','../../'); - -/** getHashedFile() function for SQSPELL_WORDS_FILE and sqgetGlobalVar() from global.php */ -include_once(SM_PATH . 'functions/prefs.php'); - /** vars needed for getHashedFile() */ global $data_dir; sqgetGlobalVar('username', $username, SQ_SESSION); @@ -32,7 +26,7 @@ sqgetGlobalVar('username', $username, SQ_SESSION); * $SQSPELL_APP = array('English' => '/usr/local/bin/aspell -a'); * * Sometimes you have to specify full path for PHP to find it. - * + * * You can use Aspell or Ispell spellcheckers, the command line is the * same. Aspell might provide better spellchecking for Western languages. * @@ -53,7 +47,7 @@ sqgetGlobalVar('username', $username, SQ_SESSION); *
  • Whatever your setting is, don't omit the "-a" flag.
  • *
  • Remember to keep same array keys during upgrades. Don't rename them. * Users' dictionary settings use it.
  • - *
  • Interface might translate array key, if used key is present in + *
  • Interface might translate array key, if used key is present in * SquirrelMail translations.
  • * *
    @@ -67,6 +61,29 @@ sqgetGlobalVar('username', $username, SQ_SESSION);
     $SQSPELL_APP = array('English' => 'ispell -a',
                          'Spanish' => 'ispell -d spanish -a');
     
    +/**
    + * Sample configuration for PHP pspell extension. Sets dictionary options.
    + * Each language definition can contain up to 3 comma delimited options.
    + * First option sets language, second sets spelling, third one sets jargon.
    + * See http://www.php.net/pspell-new
    + * 
    + * Pspell extension is supported since 0.6 (sm 1.5.2)
    + */
    +//$SQSPELL_APP = array('English' => 'en',
    +//                     'Spanish' => 'es');
    +
    +/**
    + * 0 - default, command line ispell or aspell utilities configured with SQSPELL_APP
    + * 1 - use php pspell extension. WARNING requires different SQSPELL_APP options.
    + */
    +$SQSPELL_SPELLCHECKER = 0;
    +
    +/**
    + * Can be used to turn of detection of proc_open support in command line spellcheck
    + * module. Option is not used if $SQSPELL_SPELLCHECKER is set to 1.
    + */
    +$SQSPELL_FORCE_POPEN = false;
    +
     /**
      * Default dictionary
      * @global string $SQSPELL_APP_DEFAULT
    @@ -78,7 +95,7 @@ $SQSPELL_APP_DEFAULT = 'English';
      *
      * $SQSPELL_WORDS_FILE is a location and mask of a user dictionary file.
      * The default setting should be OK for most everyone.
    - *     
    + *
      * This setting is used only when SquirrelSpell is upgraded from
      * older setup. Since SquirrelMail 1.5.1 SquirrelSpell stores all settings in
      * same place that stores other SquirrelMail user preferences.
    @@ -88,11 +105,3 @@ $SQSPELL_APP_DEFAULT = 'English';
     $SQSPELL_WORDS_FILE =
        getHashedFile($username, $data_dir, "$username.words");
     
    -/**
    - * Function used for checking words in user's dictionary
    - * @global string $SQSPELL_EREG
    - * @deprecated It is not used since 1.5.1 (sqspell 0.5)
    - */
    -$SQSPELL_EREG = 'ereg';
    -
    -?>