Class XF

Description

XF handles all low-level including initialization, database connection and basic abstraction layers

XF handles all low-level including initialization, database connection and basic abstraction layers

Located in /lb_private/class.root.php (line 57)


	
			
Class Constant Summary
 ANNOY_TIMESPAN = '10,20'
 BRANCH = 'stable'
 DATE_RFC822 = 'D, d M Y H:i:s O'
 DEBUG = false
 DEBUG_DEBUG = false
 POST_MAXLEN = 20000
 RSS_LAST = 2147483638
 RSS_MOD_UNAPPROVE = 2147483639
 VAULT_PUBLIC = 0x01
 VAULT_RO = 0x08
 VAULT_RW = 0x04
 VERSION = '1.2.0'
Variable Summary
static array $annoyances
static array $checksum
static array $config
static array $config_data
static array $group
static array $lang
static resource $sql
static boolean $sql_had_error
static boolean $sql_simulate
static array $style
static boolean $tables_complete
static array $tags
static array $tbl
static resource $tpl
static array $user
static array $vault
static integer $vtoken
Method Summary
static boolean access_control (string $action, [integer $uid = 0], [integer $gid = 0])
static string advhash (string $input, [boolean $salt = true])
static string arr2str (array $a)
static string bool2yn (boolean $a)
static mixed chksum_query (string $class, string $name, [string $data = ''])
static string clear_query_string (string $a, [string $b = ''])
static boolean convert_to_utf8 (array $a)
static boolean cookie (string $a, mixed $b, [mixed $c = 0])
static string date ([integer $a = 0], [string $b = ''], [boolean $c = false])
static mixed file_handler (string $fd, [string $data = ''], [string $flags = ''])
static mixed get_cfg (string $a)
static array get_cfg_data ()
static array get_env ()
static mixed get_group ([integer $a = 0])
static string get_masqueraded_folder (integer $a)
static array get_table_list ()
static array get_user ([array $uid = 0])
static true get_user_group_data ()
static void hash ()
static string hash_cache_keys (mixed $a, [boolean $b = true])
static mixed ifset (string $class, string $name, string $default)
static true init_annoyances ()
static true init_begin ()
static true init_cache ()
static true init_cfg ([boolean $safemode = false])
static true init_db ()
static true init_end ()
static true init_env ()
static true init_i18n ()
static true init_style ()
static boolean init_task ()
static true init_tpl ()
static true init_user ()
static string link (string $action, [mixed $params = array()], [boolean $encode_amp = true])
static boolean logger ()
static true logger_parse_message ( &$r, object $r)
static void maintenance_mode ()
static boolean reload_safe_cfg ()
static boolean reset_tpl ()
static array rscandir (string $base, [boolean $list_files = true], [ &$data = array()], array $data)
static mixed sanitize_var (string $input, string $class, [string $flags = ''])
static string scramble (string $a, [string $b = 'auto'], [string $c = 'ARC4'])
static object spam_filter (string $a, string $b, string $c)
static integer spam_result_to_marker (object $a)
static mixed sql_lastId (string $a)
static mixed sql_query (string $query, [array $params = array()], [string $method = ''], [integer $line = 0])
static boolean sql_transaction (string $class, [array $params = array()])
static boolean statistic (string $a)
static string strip_trailing_slash (string $a)
static boolean tan (string $a, [ $b = '+'])
static string tbl (string $a, [boolean $b = false])
static void terminate (string $msg, [boolean $beautify = false])
static string token (integer $a, [string $b = 'int'], [string $c = 'weak'])
static true tpl_use_cache_pool (integer $a, string $b)
static boolean update_local_cache (string $a, integer $b, string $c, mixed $d)
static string uuid ()
static boolean validate_gpc_data (array $a)
static mixed vault_query (string $name, [string $value = ''], [string $flags = ''])
boolean __construct ([string $mode = 'regular'], [array $options = array()])
void __destruct ()
Variables
static array $annoyances = array(
'SHOW_BLANK_PAGE','PUT_IN_ANTEROOM','MAINTENANCE_MESSAGE','RANDOM_HTTP_ERROR','LOGOUT_THIS_TIME',
'REDIRECT_TO_INDEX','SCHABERNACK_MACHEN','KILL_AUTHENTICATION'
)
(line 290)
  • var: some annoyances for inconvenient users
  • access: protected
static array $checksum = array() (line 151)
  • var: simple checksum storage
  • access: protected
static array $config = array() (line 139)
  • var: parsed configuration vars
  • access: protected
static array $config_data = array( // root_* should always be first!
'_'=>array('int'),'root_uri'=>array('uri'),'root_path'=>array('path'),'auth_activate_limit'=>array('utime'),'auth_bind_agent'=>array('bool'),'auth_bind_ip'=>array('bool'),'auth_max_faillogin'=>array('int'),'auth_max_lifetime'=>array('utime'),'auth_use_reauth'=>array('bool'),'auth_use_tan'=>array('bool'),'cache_acl'=>array('bool'),'cache_config'=>array('bool'),'cache_main'=>array('bool'),'cache_rss'=>array('bool'),'cache_topic'=>array('bool'),'cache_tpl'=>array('bool'),'cache_user'=>array('bool'),'cookie_autologin'=>array('str'),'cookie_domain'=>array('hostname','okifempty'),'cookie_path'=>array('path','okifempty'),'cookie_read_tracker'=>array('str'),'cookie_session'=>array('str'),'cookie_ssl_only'=>array('bool'),'filter_enable'=>array('bool'),'filter_max_age_ip4'=>array('utime'),'filter_max_age_msg'=>array('utime'),'filter_max_age_uid'=>array('utime'),'filter_sink_dnsbl_server'=>array('str','okifempty'),'filter_sink_local_class'=>array('str','okifempty'),'filter_sink_local_param'=>array('str','okifempty'),'filter_size'=>array('int'),'filter_spam_action'=>array('enum','o=reject,o=mark,o=accept'),'filter_threshold'=>array('int'),'help_class'=>array('enum','o=mail,o=direct'),'help_mail_address'=>array('mail','okifempty'),'http_detect_language'=>array('bool'),'http_output_zlib'=>array('bool'),'http_proxy'=>array('hostname','okifempty'),'http_rewrite_enable'=>array('bool'),'http_rewrite_server'=>array('enum','o=apache,o=lighttpd'),'log_enable'=>array('bool'),'log_forward'=>array('enum','o=none,o=filetxt,o=filexml,o=syslog'),'log_ip'=>array('bool'),'log_max_age'=>array('utime'),'log_parameter'=>array('str'),'log_statistic'=>array('bool'),'mail_from_mail'=>array('mail'),'mail_from_name'=>array('str'),'mail_signing_class'=>array('str','okifempty'),'mail_signing_enable'=>array('bool'),'mail_signing_param'=>array('str','okifempty'),'main_debug_verbose'=>array('bool'),'main_default_group'=>array('int'),'main_enable'=>array('bool'),'main_guest_uid'=>array('int'),'main_language'=>array('lang'),'main_post_edit_limit'=>array('utime'),'main_post_per_page'=>array('int'),'main_style'=>array('style'),'main_tags_on_index'=>array('int'),'main_title'=>array('str'),'main_topic_navbar'=>array('bool'),'main_topic_per_page'=>array('int'),'main_umask'=>array('str','okifempty,forcestr'),'main_uuid'=>array('str'),'main_version'=>array('int'),'param_action'=>array('str'),'param_ajax'=>array('uri'),'param_file'=>array('uri'),'rss_limit'=>array('int'),'rss_payload'=>array('bool'),'task_enable'=>array('bool'),'uri_css'=>array('uri'),'uri_gfx'=>array('uri'),'uri_js'=>array('uri'))
(line 210)
  • var: required configuration variables and their allowed content
  • access: protected
static array $group = array() (line 147)
  • var: cached group data
  • access: protected
static array $lang = array() (line 179)
  • var: language strings
  • access: public
static resource $sql = null (line 159)
  • var: sql resource handler
  • access: public
static boolean $sql_had_error = false (line 167)
  • var: becomes 'true', if any error during query occured
  • access: public
static boolean $sql_simulate = false (line 163)
  • var: only simulate query execution
  • access: public
static array $style = array() (line 155)
  • var: style definitions: stylesheets and imageset
  • access: public
static boolean $tables_complete = false (line 171)
  • var: were all required tables found in database?
  • access: protected
static array $tags = array() (line 183)
  • var: cached posting tags
  • access: public
static array $tbl = array(
'parsed'=>false,
'acl'=>'$P acl',
'config'=>'$P config',
'config_task'=>'$P config_task',
'group'=>'$P group',
'log'=>'$P log',
'post_data'=>'$P post_data',
'post_meta'=>'$P post_meta',
'post_prefix'=>'$P post_prefix',
'post_rating'=>'$P post_rating',
'search_result'=>'$P search_result',
'statistic'=>'$P statistic',
'tag_data'=>'$P tag_data',
'tag_meta'=>'$P tag_meta',
'user'=>'$P user',
'user_blacklist'=>'$P user_blacklist',
'user_bookmark'=>'$P user_bookmark',
'user_request'=>'$P user_request'
)
(line 187)
  • var: available tables in database
  • access: protected
static resource $tpl = null (line 175)
  • var: template engine handler
  • access: public
static array $user = array() (line 143)
  • var: cached user data
  • access: protected
static array $vault = array() (line 135)
  • var: our 'vault' - global variables for XF can be stored here
  • access: protected
static integer $vtoken = null (line 131)
  • var: token for accessing protected vars in 'vault'
  • access: protected
Methods
static method access_control (line 1316)

check if selected user can access an 'action'

check if selected user can access an 'action'

  • since: 1.0.0
  • access: public
static boolean access_control (string $action, [integer $uid = 0], [integer $gid = 0])
  • string $action: name of action
  • integer $uid: user id, current if not given
  • integer $gid: group id, current if not given
static method advhash (line 1193)

hash a bitstream e.

hash a bitstream e.g. plaintext password and use an (optional) better salting than before

  • since: 1.1.0
  • access: public
static string advhash (string $input, [boolean $salt = true])
  • string $input: input stream
  • boolean $salt: add salt to password soup?
static method arr2str (line 2351)

narrows an array down to string

narrows an array down to string

  • since: 1.0.0
  • access: public
static string arr2str (array $a)
  • array $a: input stream
static method bool2yn (line 2373)

transforms a bool to 'yes' or 'no'

transforms a bool to 'yes' or 'no'

  • since: 1.0.0
  • access: public
static string bool2yn (boolean $a)
  • boolean $a: input stream
static method chksum_query (line 1794)

store a checksum locally and compare it, if requested

store a checksum locally and compare it, if requested

  • since: 1.0.0
  • access: public
static mixed chksum_query (string $class, string $name, [string $data = ''])
  • string $class: 'get' does a comparison and 'put' stores a hash of input
  • string $name: name
  • string $data: sha1 hash on 'put' for later comparison
static method clear_query_string (line 2328)

clears a query string from unencoded chars

clears a query string from unencoded chars don't use it on $_GET and $_REQUEST as they are already decoded!

  • since: 1.0.0
  • access: public
static string clear_query_string (string $a, [string $b = ''])
  • string $a: query string
  • string $b: flags: force_decode, strip_html
static method convert_to_utf8 (line 2304)

converts a string to unicode, if not already in this encoding

converts a string to unicode, if not already in this encoding

  • since: 1.0.0
  • access: public
static boolean convert_to_utf8 (array $a)
  • array $a: input stream
static method cookie (line 1081)

set a cookie. is automatically disabled, if suhosin is detected and it already encrypts cookies.

set a cookie. encrypted by default; not very tight, but (maybe) enough to beat junior black-hats ;) is automatically disabled, if suhosin is detected and it already encrypts cookies.

  • since: 1.0.0
  • access: public
static boolean cookie (string $a, mixed $b, [mixed $c = 0])
  • string $a: name of cookie
  • mixed $b: value to store, set null to remove
  • mixed $c: expiry time, can be integer or like '3d' for three days (default is '0' -> session-only)
static method date (line 2226)

format a date output

format a date output

  • since: 1.0.0
  • access: public
static string date ([integer $a = 0], [string $b = ''], [boolean $c = false])
  • integer $a: input timestamp, should be UTC
  • string $b: resulting date format (default is RFC 822)
  • boolean $c: if 'true', output is 'human readable'
static method file_handler (line 1246)

all-purpose file handler - abstracts common php code snippets

all-purpose file handler - abstracts common php code snippets flags: read,write,delete,noroot,local,remote,append,verify,compression=[none|auto|gz|bz2]

  • since: 1.0.0
  • access: public
static mixed file_handler (string $fd, [string $data = ''], [string $flags = ''])
  • string $fd: filename
  • string $data: input stream if writing
  • string $flags: options - have a look at method description for details
static method get_cfg (line 1632)

get a configuration value

get a configuration value

  • since: 1.0.0
  • access: public
static mixed get_cfg (string $a)
  • string $a: key or '*' for all
static method get_cfg_data (line 1068)

get current supported configuration values

get current supported configuration values

  • since: 1.0.0
  • access: public
static array get_cfg_data ()
static method get_env (line 1059)

get vars from 'vault'

get vars from 'vault'

  • since: 1.0.0
  • access: public
static array get_env ()
static method get_group (line 1711)

get group data

get group data

  • since: 1.0.0
  • access: public
static mixed get_group ([integer $a = 0])
  • integer $a: group id, current if not given. '*' returns all.
static method get_masqueraded_folder (line 2109)

count set bits in input and returns them as hex

count set bits in input and returns them as hex

  • since: 1.0.0
  • access: public
static string get_masqueraded_folder (integer $a)
  • integer $a: input stream
static method get_table_list (line 1030)

fetch a list of all tables currently stored in database

fetch a list of all tables currently stored in database

  • since: 1.0.0
  • access: public
static array get_table_list ()
static method get_user (line 1647)

get user data - return data, if found, and caches it in class vars

get user data - return data, if found, and caches it in class vars

  • since: 1.0.0
  • access: public
static array get_user ([array $uid = 0])
  • array $uid: user id, current if not given. if array, the first user is returned.
static method get_user_group_data (line 976)

fetches user group from database and store them in class vars

fetches user group from database and store them in class vars

  • since: 1.0.0
  • access: protected
static true get_user_group_data ()
static method hash (line 1182)

hash a bitstream e.

hash a bitstream e.g. plaintext password

  • see: XF::advhash()
  • deprecated: replaced by advhash() since version 1.1.0
  • since: 1.0.0
  • access: public
static void hash ()
static method hash_cache_keys (line 1378)

calculate the hash from input - usuable on non-scalar values

calculate the hash from input - usuable on non-scalar values

  • since: 1.0.0
  • access: public
static string hash_cache_keys (mixed $a, [boolean $b = true])
  • mixed $a: input stream
  • boolean $b: if 'true', use keys instead of values from input as long as it is an array
static method ifset (line 1875)

returns value if is set otherwise a default

returns value if is set otherwise a default

  • since: 1.0.0
  • access: public
static mixed ifset (string $class, string $name, string $default)
  • string $class: location to look: 'get', 'post' or other
  • string $name: name of variable
  • string $default: default value to return, if not set
static method init_annoyances (line 873)

well, prepare some fun for inconvenient users *haha*

well, prepare some fun for inconvenient users *haha*

  • since: 1.0.0
  • access: protected
static true init_annoyances ()
static method init_begin (line 403)

initialize basics: check php settings and prepare user input arrays

initialize basics: check php settings and prepare user input arrays

  • since: 1.0.0
  • access: protected
static true init_begin ()
static method init_cache (line 489)

initialize caching system

initialize caching system

  • since: 1.0.0
  • access: protected
static true init_cache ()
static method init_cfg (line 507)

process configuration

process configuration

  • since: 1.0.0
  • access: protected
static true init_cfg ([boolean $safemode = false])
  • boolean $safemode: use safemode while loading? if 'true', we read it plain from db and do no post processing.
static method init_db (line 2385)

initialize database connection

initialize database connection

  • since: 1.0.0
  • access: public
static true init_db ()
static method init_end (line 920)

set 'action' to run, access checks and set basic template vars

set 'action' to run, access checks and set basic template vars

  • since: 1.0.0
  • access: protected
static true init_end ()
static method init_env (line 459)

intialize common variables and prepare database table array

intialize common variables and prepare database table array

  • since: 1.0.0
  • access: protected
static true init_env ()
static method init_i18n (line 805)

fetch core language file and detect preferred language by browser settings

fetch core language file and detect preferred language by browser settings

  • since: 1.0.0
  • access: protected
static true init_i18n ()
static method init_style (line 856)

load and prepare imageset along stylesheet definitions

load and prepare imageset along stylesheet definitions

  • since: 1.0.0
  • access: protected
static true init_style ()
static method init_task (line 613)

run a scheduled task, if enabled.

run a scheduled task, if enabled.

  • since: 1.0.0
  • access: protected
static boolean init_task ()
static method init_tpl (line 694)

prepare smarty template engine handing html outputs

prepare smarty template engine handing html outputs

  • since: 1.0.0
  • access: protected
static true init_tpl ()
static method init_user (line 724)

initialize user data and cache group data

initialize user data and cache group data

  • since: 1.0.0
  • access: protected
static true init_user ()
static method link (line 2260)

parse a link

parse a link

  • since: 1.0.0
  • access: public
static string link (string $action, [mixed $params = array()], [boolean $encode_amp = true])
  • string $action: use 'action'
  • mixed $params: any params to append?
  • boolean $encode_amp: if 'true', ampersands are encoded to '&'
static method logger (line 1418)

forward an entry to log system deliver input as args: first is level 'system', 'info' or 'error'.

forward an entry to log system deliver input as args: first is level 'system', 'info' or 'error'. any following are combined as message. odd [1,3,5,...] become a 'description' for an entry. even [2,4,6,...] are its message. you may also pass all args in an array as first argument. example: logger('info','foo','bar','userid',3,'select','false') or logger(array('info','foo','bar','userid',3,'select','false'))

  • since: 1.0.0
  • access: public
static boolean logger ()
static method logger_parse_message (line 1461)

parse logging messages for (human readable) output

parse logging messages for (human readable) output

  • since: 1.0.0
  • access: public
static true logger_parse_message ( &$r, object $r)
  • object $r: results of log entry from database
  • &$r
static method maintenance_mode (line 1860)

output maintenance message and end execution

output maintenance message and end execution

  • since: 1.0.0
  • access: public
static void maintenance_mode ()
static method reload_safe_cfg (line 1050)

reload configuration table by using safe mode

reload configuration table by using safe mode

  • since: 1.0.0
  • access: public
static boolean reload_safe_cfg ()
static method reset_tpl (line 1591)

reset all template vars except common one

reset all template vars except common one

  • since: 1.0.0
  • access: public
static boolean reset_tpl ()
static method rscandir (line 2124)

scan through folders recursively

scan through folders recursively

  • since: 1.0.0
  • access: public
static array rscandir (string $base, [boolean $list_files = true], [ &$data = array()], array $data)
  • string $base: base folder
  • boolean $list_files: if true, also list files
  • array $data: data stream
  • &$data
static method sanitize_var (line 1900)

sanitize user inputs - very(!) important

sanitize user inputs - very(!) important available flags: okifempty,forcestr,enforce,stripspaces,notrim,restrict,fullascii,hex,oct,length=,range=,o= 'str,strwbr,path,file' are *sanitizing* (strip illegal chars), others are *validating* (return 'false' on illegal chars) normally we do not allow empty input (zero strlen), use 'okifempty' flag to change this! hex|oct do not support 'range='

  • since: 1.0.0
  • access: public
static mixed sanitize_var (string $input, string $class, [string $flags = ''])
  • string $input: input stream
  • string $class: validate against what type?
  • string $flags: some flags - see method for details
static method scramble (line 1109)

(de)scramble a string using cryptography

(de)scramble a string using cryptography

  • since: 1.0.0
  • access: public
static string scramble (string $a, [string $b = 'auto'], [string $c = 'ARC4'])
  • string $a: input stream
  • string $b: use 'auto' mode or 'encrypt' respectively 'decrypt'
  • string $c: select algorithm: 'ARC4' is fast and 'Blowfish' is slow, but more secure
static method spam_filter (line 1541)

forward input data through filtering api to detect unwanted messages ("spam")

forward input data through filtering api to detect unwanted messages ("spam")

  • since: 1.1.0
  • access: public
static object spam_filter (string $a, string $b, string $c)
  • string $a: user id, current if empty
  • string $b: client ip address, current if empty
  • string $c: the message
static method spam_result_to_marker (line 1575)

transform result cache to marker for database storage

transform result cache to marker for database storage pd_spam_marker: 0=not scanned, 1=ham, 2=spam

  • since: 1.1.0
  • access: public
static integer spam_result_to_marker (object $a)
  • object $a: instance of XFFilter after scanning
static method sql_lastId (line 2618)

return last inserted id after sql query

return last inserted id after sql query

  • since: 1.0.0
  • access: public
static mixed sql_lastId (string $a)
  • string $a: resource descriptor - currently only for postgres
static method sql_query (line 2458)

perform a sql query

perform a sql query first char can be a flag: ?=debug selects, -=just simulate and !=only output query params === '-' -> do not log query in debug trace AND no check before execution if table exists

  • since: 1.0.0
  • access: public
static mixed sql_query (string $query, [array $params = array()], [string $method = ''], [integer $line = 0])
  • string $query: the query
  • array $params: params for prepared statements
  • string $method: what method issued it?
  • integer $line: on which line?
static method sql_transaction (line 2542)

transaction abstraction layer

transaction abstraction layer mysql gets a simulation by locking because it (still/actually) lacks transactions *sigh* you should not use nested transactions to allow using databases not support them

  • since: 1.0.0
  • access: public
static boolean sql_transaction (string $class, [array $params = array()])
  • string $class: 'begin', 'commit', 'rollback' or 'is_running', may contain a name separated by colon
  • array $params: additional table locks for databases not supporting transactions
static method statistic (line 1501)

increase statistic counter by one

increase statistic counter by one

  • since: 1.0.0
  • access: public
static boolean statistic (string $a)
  • string $a: descriptor - see statistic table for details. separate multiple by comma.
static method strip_trailing_slash (line 2080)

strips trailing slashes

strips trailing slashes

  • since: 1.0.0
  • access: public
static string strip_trailing_slash (string $a)
  • string $a: input stream
static method tan (line 1161)

store a transaction number to session for using in forms

store a transaction number to session for using in forms

  • since: 1.0.0
  • access: public
static boolean tan (string $a, [ $b = '+'])
  • string $a: requested 'action'
  • $b
static method tbl (line 1221)

returns a valid database table name for usage in sql queries

returns a valid database table name for usage in sql queries

  • since: 1.0.0
  • access: public
static string tbl (string $a, [boolean $b = false])
  • string $a: name of table (keys of array XF::tbl()), '*' selects all
  • boolean $b: if 'true', returns raw value
static method terminate (line 1820)

terminate script execution and output error message

terminate script execution and output error message

  • since: 1.0.0
  • access: public
static void terminate (string $msg, [boolean $beautify = false])
  • string $msg: input stream
  • boolean $beautify: if 'true', displays some nice error messages for users instead of 'cold' exception report
static method token (line 2150)

create a token - useful on creating passwords or digests

create a token - useful on creating passwords or digests int=0-9, strict=a-f0-9, alnum=a-zA-Z0-9, binary=x00-xff

  • since: 1.0.0
  • access: public
static string token (integer $a, [string $b = 'int'], [string $c = 'weak'])
  • integer $a: length of token
  • string $b: choose token type: 'int', 'strict', 'alnum' or 'binary'
  • string $c: using 'strong' here creates a token for cryptographic use, forces 'binary'
static method tpl_use_cache_pool (line 1393)

rewire template engine cache to 'pool' when required

rewire template engine cache to 'pool' when required

  • since: 1.0.0
  • access: public
static true tpl_use_cache_pool (integer $a, string $b)
  • integer $a: id translated by 'XF::get_masqueraded_folder()'
  • string $b: use 'begin' first, then 'change' to alter the folders and 'reset' after work
static method update_local_cache (line 1613)

update the local caches like self::$user with new values

update the local caches like self::$user with new values

  • since: 1.0.0
  • access: public
static boolean update_local_cache (string $a, integer $b, string $c, mixed $d)
  • string $a: cache identifier (currently 'user' only)
  • integer $b: identifier of cache entry
  • string $c: name of dataset
  • mixed $d: new value
static method uuid (line 1142)

create an 'universal unique identifier'.

create an 'universal unique identifier'. if we didn't make a mistake on calculation, this should be about 120-bit of randomness... output example: 550e8400-e29b-11d4-a716-446655440000 (not really strict RFC!)

  • since: 1.0.0
  • access: public
static string uuid ()
static method validate_gpc_data (line 2092)

validates input array for rejected 'false' data

validates input array for rejected 'false' data

  • since: 1.0.0
  • access: public
static boolean validate_gpc_data (array $a)
  • array $a: input stream
static method vault_query (line 1731)

our 'vault': values can be stored here for class-wide reference

our 'vault': values can be stored here for class-wide reference flags: pub,rw,required,token=

  • since: 1.0.0
  • access: public
static mixed vault_query (string $name, [string $value = ''], [string $flags = ''])
  • string $name: name, '*' fetches all
  • string $value: data
  • string $flags: options, default is protected and read-only
Constructor __construct (line 303)

start your engines :)

start your engines :) options: 'initcfg_file' - user defined path to initial configuration

  • since: 1.0.0
  • access: public
boolean __construct ([string $mode = 'regular'], [array $options = array()])
  • string $mode: select mode to execute: 'regular', 'ajax' or 'setup'
  • array $options: options - see method for details
Destructor __destruct (line 388)

well, clean up after work and turn off the lights.

well, clean up after work and turn off the lights...

  • since: 1.0.0
  • access: public
void __destruct ()
Class Constants
ANNOY_PROBABILITY_ON_AJAX = 75 (line 115)
  • var: probability in percent a user gets annoyed on asynchronous requests, if enabled
ANNOY_TIMESPAN = '10,20' (line 111)
  • var: between x and y seconds we annoy an user on "regular" use, if enabled
BRANCH = 'stable' (line 79)
  • var: what branch does this release belong to
DATABASE_VERSION = 10 (line 75)
  • var: demands this database version
DATE_RFC822 = 'D, d M Y H:i:s O' (line 127)
  • var: use this formatting to be complaint to RFC 822
DEBUG = false (line 61)
  • var: debugging mode for developers - activates lots more verbosity...
DEBUG_DEBUG = false (line 65)
  • var: well, do the same even in external libaries, where we installed our debugging hooks...
ENABLE_SCRAMBLE = true (line 103)
  • var: if 'true', we use encryption for cookies
POST_MAXLEN = 20000 (line 107)
  • var: maximal length of posting messages
RSS_LAST = 2147483638 (line 119)
  • var: mapped post id for last posts in rss feed (2^31-10)
RSS_MOD_UNAPPROVE = 2147483639 (line 123)
  • var: mapped post id for unapproved posts in rss feed (2^31-9)
TASK_INTERVAL = 3 (line 99)
  • var: run scheduled tasks every x minutes
VAULT_PROTECTED = 0x02 (line 91)
  • var: bit for 'vault': access requires token
VAULT_PUBLIC = 0x01 (line 95)
  • var: bit for 'vault': public access
VAULT_RO = 0x08 (line 83)
  • var: bit for 'vault': read-only access
VAULT_RW = 0x04 (line 87)
  • var: bit for 'vault': writeable access
VERSION = '1.2.0' (line 71)
  • var: the current software version

Documentation generated on Sun, 20 Jun 2010 11:59:16 +0200 by phpDocumentor 1.4.3