Annotation of embedaddon/php/ext/pgsql/tests/lcmess.inc, revision 1.1.1.1

1.1       misho       1: <?php
                      2: 
                      3: function _skip_lc_messages($lc_messages = 'C')
                      4: {
                      5:        if (!_set_lc_messages($lc_messages)) {
                      6:                die("skip Cannot set LC_MESSAGES to '{$lc_messages}'\n");
                      7:        }
                      8: }
                      9: 
                     10: function _set_lc_messages($lc_messages = 'C')
                     11: {
                     12:        if (pg_result(pg_query("SHOW LC_MESSAGES"), 0, 0) != $lc_messages) {
                     13:                if (!@pg_exec("SET LC_MESSAGES='{$lc_messages}'")) {
                     14:                        return false;
                     15:                }
                     16:        }
                     17: 
                     18:        return true;
                     19: }
                     20: 
                     21: ?>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>