Ignore:
Timestamp:
08/15/10 18:45:12 (22 months ago)
Author:
vain
Message:
  • several changes to copyright, router, bootstrap, frontcontroller and various other files
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/core/localization.core.php

    r4544 r4578  
    2424    * 
    2525    * @license    GNU/GPL v2 or (at your option) any later version, see "/doc/LICENSE". 
    26     * 
    2726    * @author     Jens-André Koch <vain@clansuite.com> 
    2827    * @copyright  Jens-André Koch (2005 - onwards) 
    29     * 
    3028    * @link       http://www.clansuite.com 
    31     * @link       http://gna.org/projects/clansuite 
    32     * 
     29    *  
    3330    * @version    SVN: $Id$ 
    3431    */ 
     
    4239/** 
    4340 * Clansuite Core Class for Localization (l10n) & Internationalization (i18n) Handling 
    44  * 
    45  * @author     Jens-André Koch   <vain@clansuite.com> 
    46  * @copyright  Jens-André Koch (2005 - onwards) 
    4741 * 
    4842 * @category    Clansuite 
     
    6660 
    6761    # References 
    68     private $config    = null; 
     62    private static $config    = null; 
    6963 
    7064    public function __construct(Clansuite_Config $config) 
    7165    { 
    7266        # Set Reference to Config 
    73         $this->config = $config; 
     67        self::$config = $config; 
    7468 
    7569        # Set Locale Defaults 
    7670        $this->domain = 'clansuite'; 
    77         $this->encoding = $config['language']['outputcharset']; 
     71        $this->encoding = self::$config['language']['outputcharset']; 
    7872 
    7973        # Get Locale 
     
    10195         * @link http://www.gnu.org/software/gettext/manual/gettext.html GNU Gettext 
    10296         */ 
    103         if ( function_exists('_get_reader') === false ) 
     97        if(function_exists('_get_reader') === false) 
    10498        { 
    10599            include ROOT_LIBRARIES . '/php-gettext/gettext.inc'; 
     
    131125            if(empty($this->locale)) # 3) get the default language from config as fallback 
    132126            { 
    133                 $this->locale = $this->config['language']['language']; 
     127                $this->locale = self::$config['language']['language']; 
    134128            } 
    135129        } 
     
    154148    public function loadTextDomain($category, $domain, $locale, $module = null) 
    155149    { 
    156         # if, $locale string is not over 3 -> $locale = "en", build "en_EN" 
     150        #Clansuite_Debug::firebug($module); 
     151 
     152        # if, $locale string is not over 3 chars long -> $locale = "en", build "en_EN" 
    157153        if(isset($locale{3}) == false) 
    158154        { 
     
    174170            $domain_directory = ROOT_LANGUAGES; 
    175171        } 
    176         else # tp a specific module directory 
    177         { 
    178  
     172        else # set a specific module directory 
     173        { 
    179174            $domain_directory = ROOT_MOD . $module . DS . 'languages' . DS; 
    180175        } 
     
    185180        T_textdomain($domain); 
    186181 
    187         #Clansuite_Debug::firebug('<p>Textdomain "' .$domain .'" loaded from path "'. $domain_directory .'"</p>'); 
     182        #Clansuite_Debug::firebug('<p>Textdomain "' .$domain .'" loaded from path "'. $domain_directory .'" for "'. $module .'"</p>'); 
    188183        return true; 
    189184    } 
Note: See TracChangeset for help on using the changeset viewer.