ManiaLib 1.0b1 API Reference

File/config.default.php

Description

Framework default config

This is the default configuration file. You shouldn't modify anything in this file. Instead, override the constants you want in your "config.php" file.

Constants
APP_CONFIG_PATH = APP_PATH.'config/' (line 147)

Config path

Path to the directory containing the config files of your application

APP_DATABASE_CHARSET = 'utf8' (line 310)

MySQL charset

APP_DATABASE_HOST = 'localhost' (line 281)

MySQL database hostname

APP_DATABASE_NAME = 'manialib' (line 302)

MySQL database name

APP_DATABASE_PASSWORD = '' (line 295)

MySQL database password

APP_DATABASE_USER = 'root' (line 288)

MySQL database username

APP_DATA_DIR_URL = APP_URL.'data/' (line 174)

Data directory URL

URL of the directory when your store misc data of your application

APP_DEBUG_LEVEL = 0 (line 274)

Debug level

USE "0" FOR PRODUCTION ENVIRONEMENT !

If 1, all the debug messages and the errors will be outputed to the screen.

If 0, only the user messages are shown in case of error

APP_DEBUG_LOG = APP_LOGS_PATH.'debug.log' (line 202)

Debug log

All the debug messages will be logged in this file

APP_DEFAULT_TIMEZONE = 'Europe/Paris' (line 233)

Time zone

Default time zone of the server

APP_ERROR_LOG = APP_LOGS_PATH.'error.log' (line 183)

Error log

All the runtime errors will be logged in this file

APP_FRAMEWORK_GUI_TOOLKIT_PATH = APP_FRAMEWORK_PATH.'gui-toolkit/' (line 102)

GUI Toolkit path

Path to the GUI Toolkit of the framework

APP_FRAMEWORK_LANGS_PATH = APP_FRAMEWORK_PATH.'langs/' (line 84)

Framework lang path

Default dictionaries of the framework

APP_FRAMEWORK_LIBRARIES_PATH = APP_FRAMEWORK_PATH.'libraries/' (line 93)

Framework libraries path

Path to the "libraries" directory of the framework

APP_FRAMEWORK_PATH = APP_PATH.'manialib/' (line 75)

Framework path

This is the path to the "manialib/" directory

APP_FRAMEWORK_REQUEST_ENGINE_CLASS = 'RequestEngine' (line 319)

Request engine class

Define the right request engine class depending on the mvc framework usage

APP_IMAGE_DIR_URL = APP_URL.'images/' (line 165)

Images directory URL

URL of the directory when you store the images of your application

APP_INCLUDE_PATH = APP_PATH.'include/' (line 138)

Include path

Misc include path, to put anything that is not a class

APP_LANGS_PATH = APP_PATH.'langs/' (line 120)

Lang path

Directory containing the XML dictionaries for internationalizing your application

APP_LANG_ENGINE_MODE = 1 (line 260)

Lang engine mode

If set to "1", it will use the dynamic lang engine mode. The XML dicos will be loaded by LangEngine and you will be able to create dynamic sentances.

If set to "0", it won't do anything so you can use them as standard Manialink dictionaries. Note that you will need to include the XML files in your Manialink for localization to work. See Manialink::includeManialink() to do that

  • see: LangEngine
APP_LIBRARIES_PATH = APP_PATH.'libraries/' (line 111)

Libraries path

Path to the user libraries directory

APP_LOGS_PATH = APP_PATH.'logs/' (line 129)

Logs path

Path to the logs directory

APP_MANIAHOME_NAME = APP_MANIALINK (line 334)

Name of your Manialink for the ManiaHome favourite button.

It can have special characters.

APP_MANIAHOME_PICTURE = null (line 348)

URL of your banner for ManiaHome

APP_MANIAHOME_SHOW_BUTTON = true (line 326)

Whether to show the ManiaHome favourite button

APP_MANIAHOME_URL = APP_MANIALINK (line 341)

URL or short Manialink of your Manialink for the ManiaHome favourite button

APP_MANIALINK = 'manialib' (line 216)

Short Manialink

Short Manialink of your application. You can define Short Manialinks on the Player Page at http://player.trackmania.com

Note that the Short Manialink "manialibdev" redirects to "http://localhost/manialib/" for easy access to your local developement version

APP_PATH = dirname(__FILE__).'/../' (line 18)

Path to your application on the hard drive

APP_TIMEZONE_NAME = 'GMT+1' (line 242)

Time zone name

Human readable name of the time zone in case you need to print it

APP_URL = APP_URL_BASE.APP_URL_PATH (line 66)

Complete URL of your application.

You shouldn't have to change this value.

APP_URL_BASE = strtolower(preg_replace('/([^\/]*).*/i','$1',$_SERVER['SERVER_PROTOCOL'])).'://'.$_SERVER['HTTP_HOST'].'/' (line 30)

Base URL of your application

If your manialink is hosted at "http//yourhost. com/mymanialink/", you should put here "http://yourhost.com/". Don't forget the trailing slash.

APP_URL_PATH = $str (line 57)

URL path of your application

If your manialink is hosted at "http://yourhost. com/mymanialink/", you should put here "mymanialink/". Don't forget the trailing slash.

APP_USER_ERROR_LOG = APP_LOGS_PATH.'user-error.log' (line 193)

User error log

All the user errors (eg.someone enterded a bad parameter in a form) will be logged in this file

APP_USE_SHORT_MANIALINKS = false (line 224)

Deprecated, please don't use it

  • deprecated:
APP_WWW_PATH = APP_PATH (line 156)

Webroot path

Path to the webroot of your application.