lang::util::translator_mode_p (public)

 lang::util::translator_mode_p

Defined in packages/acs-lang/tcl/lang-util-procs.tcl

Whether translator mode is enabled for this session or not. Translator mode will cause all non-translated messages to appear as a link to a page where the message can be translated, instead of the default "not translated" message.

Returns:
1 if translator mode is enabled, 0 otherwise. Returns 0 if there is no HTTP connection.
Author:
Lars Pind <lars@collaboraid.biz>
Created:
October 24, 2002
See Also:

Testcases:
test_translator_mode
Source code:
    if {[info exists ::acs_translator_mode_p]} {
        return $::acs_translator_mode_p
    }
    if { [ns_conn isconnected] } {
        # There is an HTTP connection - return the client property
        set ::acs_translator_mode_p [ad_get_client_property -default 0 acs-lang translator_mode_p]
        if {$::acs_translator_mode_p eq ""} {
            set ::acs_translator_mode_p 0
        }
    } else {
        # No HTTP connection
        set ::acs_translator_mode_p 0
    }
    return $::acs_translator_mode_p
XQL Not present:
PostgreSQL, Oracle
Generic XQL file:
packages/acs-lang/tcl/lang-util-procs.xql

[ hide source ] | [ make this the default ]
Show another procedure: