1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
|
<?php
/**
* Metadata for configuration manager plugin
*
* Note: This file should be included within a function to ensure it
* doesn't class with the settings it is describing.
*
* Format:
* $meta[<setting name>] = array(<handler class id>,<param name> => <param value>);
*
* <handler class id> is the handler class name without the "setting_" prefix
*
* Defined classes:
* Generic
* -------------
* '' - default class ('setting'), text input, minimal input validation, setting output in quotes
* 'numeric' - text input, accepts numbers and arithmetic operators, setting output without quotes
* 'onoff' - checkbox input, setting output 0|1
* 'multichoice' - select input (single choice), setting output with quotes, required _choices parameter
* 'email' - text input, input must conform to email address format, setting output in quotes
* 'password' - password input, minimal input validation, setting output plain text in quotes
* 'dirchoice' - as multichoice, selection choices based on folders found at location specified in _dir
* parameter (required)
*
* Single Setting
* --------------
* 'savedir' - as 'setting', input tested against initpath() (inc/init.php)
* 'sepchar' - as multichoice, selection constructed from string of valid values
* 'authtype' - as 'setting', input validated against a valid php file at expected location for auth files
* 'im_convert' - as 'setting', input must exist and be an im_convert module
*
* Any setting commented or missing will use 'setting' class - text input, minimal validation, quoted output
*
* Defined parameters:
* '_pattern' - string, a preg pattern. input is tested against this pattern before being accepted
* optional all classes, except onoff, multichoice & dirchoice which ignore it
* '_choices' - array of choices. used to populate a selection box. choice will be replaced by a localised
* language string, indexed by <setting name>_o_<choice>, if one exists
* required by 'multichoice' class, ignored by other classes
* '_dir' - location of directory to be used to populate choice list
* required by 'dirchoice' class, ignored by other classes
*
* @author Chris Smith <chris@jalakai.co.uk>
*/
// ---------------[ settings for settings ]------------------------------
$config['format'] = 'php'; // format of setting files, supported formats: php
$config['varname'] = 'conf'; // name of the config variable, sans $
// this string is written at the top of the rewritten settings file,
// !! do not include any comment indicators !!
// this value can be overriden when calling save_settings() method
$config['heading'] = 'Dokuwiki\'s Main Configuration File - Local Settings';
// ---------------[ setting files ]--------------------------------------
// these values can be string expressions, they will be eval'd before use
$file['local'] = "DOKU_CONF.'local.php'"; // mandatory (file doesn't have to exist)
$file['default'] = "DOKU_CONF.'dokuwiki.php'"; // optional
$file['protected'] = "DOKU_CONF.'local.protected.php'"; // optional
// test value (FIXME, remove before publishing)
//$meta['test'] = array('multichoice','_choices' => array(''));
// --------------[ setting metadata ]------------------------------------
// - for description of format and fields see top of file
// - order the settings in the order you wish them to appear
// - any settings not mentioned will come after the last setting listed and
// will use the default class with no parameters
$meta['title'] = array('');
$meta['start'] = array('');
$meta['savedir'] = array('savedir');
$meta['lang'] = array('dirchoice','_dir' => DOKU_INC.'inc/lang/');
$meta['template'] = array('dirchoice','_dir' => DOKU_INC.'lib/tpl/');
$meta['umask'] = array('numeric','_pattern' => '/0[0-7]{3}/'); // only accept octal representation
$meta['dmode'] = array('numeric','_pattern' => '/0[0-7]{3}/'); // only accept octal representation
$meta['fmode'] = array('numeric','_pattern' => '/0[0-7]{3}/'); // only accept octal representation
$meta['basedir'] = array('');
$meta['baseurl'] = array('');
$meta['fullpath'] = array('onoff');
$meta['recent'] = array('numeric');
$meta['breadcrumbs'] = array('numeric');
$meta['typography'] = array('onoff');
$meta['htmlok'] = array('onoff');
$meta['phpok'] = array('onoff');
$meta['dformat'] = array('');
$meta['signature'] = array('');
$meta['toptoclevel'] = array('multichoice','_choices' => array(1,2,3,4,5)); // 5 toc levels
$meta['maxtoclevel'] = array('multichoice','_choices' => array(0,1,2,3,4,5));
$meta['maxseclevel'] = array('multichoice','_choices' => array(0,1,2,3,4,5)); // 0 for no sec edit buttons
$meta['camelcase'] = array('onoff');
$meta['deaccent'] = array('onoff');
$meta['useheading'] = array('onoff');
$meta['refcheck'] = array('onoff');
$meta['refshow'] = array('numeric');
$meta['allowdebug'] = array('onoff');
$meta['usewordblock']= array('onoff');
$meta['indexdelay'] = array('numeric');
$meta['relnofollow'] = array('onoff');
$meta['mailguard'] = array('multichoice','_choices' => array('visible','hex','none'));
$meta['useacl'] = array('onoff');
$meta['openregister']= array('onoff');
$meta['autopasswd'] = array('onoff');
$meta['resendpasswd'] = array('onoff');
$meta['authtype'] = array('authtype');
$meta['passcrypt'] = array('multichoice','_choices' => array('smd5','md5','sha1','ssha','crypt','mysql','my411'));
$meta['defaultgroup']= array('');
$meta['superuser'] = array('');
$meta['profileconfirm'] = array('onoff');
$meta['userewrite'] = array('multichoice','_choices' => array(0,1,2));
$meta['useslash'] = array('onoff');
$meta['sepchar'] = array('sepchar');
$meta['canonical'] = array('onoff');
$meta['autoplural'] = array('onoff');
$meta['usegzip'] = array('onoff');
$meta['cachetime'] = array('numeric');
$meta['purgeonadd'] = array('onoff');
$meta['locktime'] = array('numeric');
$meta['notify'] = array('email');
$meta['mailfrom'] = array('email');
$meta['gdlib'] = array('multichoice','_choices' => array(0,1,2));
$meta['im_convert'] = array('im_convert');
$meta['spellchecker']= array('onoff');
$meta['subscribers'] = array('onoff');
$meta['compress'] = array('onoff');
$meta['hidepages'] = array('');
$meta['send404'] = array('onoff');
$meta['sitemap'] = array('numeric');
$meta['rss_type'] = array('multichoice','_choices' => array('rss','rss1','rss2','atom'));
$meta['rss_linkto'] = array('multichoice','_choices' => array('diff','page','rev','current'));
$meta['target____wiki'] = array('');
$meta['target____interwiki'] = array('');
$meta['target____extern'] = array('');
$meta['target____media'] = array('');
$meta['target____windows'] = array('');
$meta['proxy____host'] = array('','_pattern' => '#^[a-z0-9\-\.+]+?#i');
$meta['proxy____port'] = array('numeric');
$meta['proxy____user'] = array('');
$meta['proxy____pass'] = array('password');
$meta['proxy____ssl'] = array('onoff');
$meta['safemodehack'] = array('onoff');
$meta['ftp____host'] = array('','_pattern' => '#^[a-z0-9\-\.+]+?#i');
$meta['ftp____port'] = array('numeric');
$meta['ftp____user'] = array('');
$meta['ftp____pass'] = array('password');
$meta['ftp____root'] = array('');
|