global
Reserved displays/paths:
- image / ( small|medium|large ) / id - path to database stored images
- sys / ( template name ) - path to system functon templates
- file / ( open|download ) / id - path to stored files
Reserved GETs:
- lang=code - language selected
- page=x - pagination
- action=print - print template
Global variables & objects:
- $MP - myportal paths and template variables
- $CONFIG - array of configuration
- $GET - rewriten and escaped $_GET
- $POST - escaped $_POST
- $DB - database connection
- $__ - translations
$MP {#mp}
{{lang:php}}
mp: Array
(
[timer_start] => 1216212063.5938
[protocol] => http://
[host] => localhost
[url] => http://localhost/myportal2
[path] => /myportal2
[pathlang] => /myportal2
[depth] => 1
)
$CONFIG {#config}
{{lang:php}}
Array
(
[defaultlang] => si
[adminlang] => si
[statistics_update_url] => http://localhost/ip2nation.sql
[statistics_length] =>
[statistics] => 1
[image_backup_quality] => 90
[image_backup_size] => 2000
[image_backup] => 1
[datetime_format] => d.m.Y H:i:s
[date_format] => d.m.Y
[author] => Editor d.o.o.
[email] => wer@wetr.si
[websiteid] => myportal_dev
[startpage] => domov
[cache_expire] => 600
..
)
$GET {#get}
recursively escaped && translated $_GET with root url http://localhost/myportal2/
{{lang:php}}
// http://localhost/myportal2/products/fruit/bannan?order=desc&by=price
Array
(
[1] => products
[2] => fruit
[3] => bannan
[order] => desc
[by] => price
)
// http://localhost/myportal2/si/products/fruit/bannan?order=desc&by=price
Array
(
[1] => products
[2] => fruit
[3] => bannan
[lang] => si
[order] => desc
[by] => price
)
$POST {#post}
recursively escaped $_POST
$DB {#db}
go see reference
$__ {#__}
array of translations, with key as a key/default string and value as translation, depending on $GET[lang]