]> git.wh0rd.org Git - tt-rss.git/commitdiff
move function startup_gettext
authorAndrew Dolgov <fox@madoka.spb.ru>
Tue, 6 Mar 2007 10:33:06 +0000 (11:33 +0100)
committerAndrew Dolgov <fox@madoka.spb.ru>
Tue, 6 Mar 2007 10:33:06 +0000 (11:33 +0100)
functions.php
update_daemon.php

index ba92b2ee4bb61431b16ffc027b3281aa6c2fc739..f051513692e2b5eca4104aefd416c969bb89a09a 100644 (file)
 
        require_once 'config.php';
 
+       function startup_gettext() {
+
+               # Get locale from Accept-Language header
+               $lang = al2gt(array("en_US", "ru_RU"), "text/html");
+
+               if ($lang) {
+                       _setlocale(LC_MESSAGES, $lang);
+                       _bindtextdomain("messages", "locale");
+                       _textdomain("messages");
+                       _bind_textdomain_codeset("messages", "UTF-8");
+               }
+       }
+
        if (ENABLE_TRANSLATIONS == true) { 
                startup_gettext();
        }
                return print format_warning($msg);
        }
 
-       function startup_gettext() {
-
-               # Get locale from Accept-Language header
-               $lang = al2gt(array("en_US", "ru_RU"), "text/html");
-
-               if ($lang) {
-                       _setlocale(LC_MESSAGES, $lang);
-                       _bindtextdomain("messages", "locale");
-                       _textdomain("messages");
-                       _bind_textdomain_codeset("messages", "UTF-8");
-               }
-       }
-
        function T_sprintf() {
                $args = func_get_args();
                return vsprintf(__(array_shift($args)), $args);
index 312001a1711dd49ae16adfd4a5b2a295c5a7cf30..77660f09d3cc0bbb201217cd8cd130a4ddc4a562 100644 (file)
@@ -4,6 +4,7 @@
        // continuously
 
        define('DEFAULT_ERROR_LEVEL', E_ALL);
+       error_reporting(E_ALL);
 
        declare(ticks = 1);