34231bf15304750b60e97652f4de91e91d9de64a
[lhc/web/wiklou.git] / includes / Defines.php
1 <?php
2 /**
3 * A few constants that might be needed during LocalSettings.php
4 * @package MediaWiki
5 */
6
7 /**#@+
8 * Database related constants
9 */
10 define( 'DBO_DEBUG', 1 );
11 define( 'DBO_NOBUFFER', 2 );
12 define( 'DBO_IGNORE', 4 );
13 define( 'DBO_TRX', 8 );
14 define( 'DBO_DEFAULT', 16 );
15 define( 'DBO_PERSISTENT', 32 );
16 /**#@-*/
17
18 /**#@+
19 * Virtual namespaces; don't appear in the page database
20 */
21 define('NS_MEDIA', -2);
22 define('NS_SPECIAL', -1);
23 /**#@-*/
24
25 /**#@+
26 * Real namespaces
27 *
28 * Number 100 and beyond are reserved for custom namespaces;
29 * DO NOT assign standard namespaces at 100 or beyond.
30 * DO NOT Change integer values as they are most probably hardcoded everywhere
31 * see bug #696 which talked about that.
32 */
33 define('NS_MAIN', 0);
34 define('NS_TALK', 1);
35 define('NS_USER', 2);
36 define('NS_USER_TALK', 3);
37 define('NS_PROJECT', 4);
38 define('NS_PROJECT_TALK', 5);
39 define('NS_IMAGE', 6);
40 define('NS_IMAGE_TALK', 7);
41 define('NS_MEDIAWIKI', 8);
42 define('NS_MEDIAWIKI_TALK', 9);
43 define('NS_TEMPLATE', 10);
44 define('NS_TEMPLATE_TALK', 11);
45 define('NS_HELP', 12);
46 define('NS_HELP_TALK', 13);
47 define('NS_CATEGORY', 14);
48 define('NS_CATEGORY_TALK', 15);
49 /**#@-*/
50
51 /**
52 * Available feeds objects
53 * Should probably only be defined when a page is syndicated ie when
54 * $wgOut->isSyndicated() is true
55 */
56 $wgFeedClasses = array(
57 'rss' => 'RSSFeed',
58 'atom' => 'AtomFeed',
59 );
60
61 /**#@+
62 * Maths constants
63 */
64 define( 'MW_MATH_PNG', 0 );
65 define( 'MW_MATH_SIMPLE', 1 );
66 define( 'MW_MATH_HTML', 2 );
67 define( 'MW_MATH_SOURCE', 3 );
68 define( 'MW_MATH_MODERN', 4 );
69 define( 'MW_MATH_MATHML', 5 );
70 /**#@-*/
71
72 /**
73 * User rights management
74 * a big array of string defining a right, that's how they are saved in the
75 * database.
76 * @todo Is this necessary?
77 */
78 $wgAvailableRights = array('read', 'edit', 'move', 'delete', 'undelete',
79 'protect', 'block', 'userrights', 'createaccount', 'upload',
80 'rollback', 'patrol', 'editinterface', 'siteadmin', 'bot', 'validate',
81 'import', 'importupload', 'renameuser' );
82
83 /**#@+
84 * Cache type
85 */
86 define( 'CACHE_ANYTHING', -1 ); // Use anything, as long as it works
87 define( 'CACHE_NONE', 0 ); // Do not cache
88 define( 'CACHE_DB', 1 ); // Store cache objects in the DB
89 define( 'CACHE_MEMCACHED', 2 ); // MemCached, must specify servers in $wgMemCacheServers
90 define( 'CACHE_ACCEL', 3 ); // eAccelerator or Turck, whichever is available
91 /**#@-*/
92
93
94
95 /**#@+
96 * Media types.
97 * This defines constants for the value returned by Image::getMediaType()
98 */
99
100 define( 'MEDIATYPE_UNKNOWN', 'UNKNOWN' ); // unknown format
101 define( 'MEDIATYPE_BITMAP', 'BITMAP' ); // some bitmap image or image source (like psd, etc). Can't scale up.
102 define( 'MEDIATYPE_DRAWING', 'DRAWING' ); // some vector drawing (SVG, WMF, PS, ...) or image source (oo-draw, etc). Can scale up.
103 define( 'MEDIATYPE_AUDIO', 'AUDIO' ); // simple audio file (ogg, mp3, wav, midi, whatever)
104 define( 'MEDIATYPE_VIDEO', 'VIDEO' ); // simple video file (ogg, mpg, etc; no not include formats here that may contain executable sections or scripts!)
105 define( 'MEDIATYPE_MULTIMEDIA', 'MULTIMEDIA' ); // Scriptable Multimedia (flash, advanced video container formats, etc)
106 define( 'MEDIATYPE_OFFICE', 'OFFICE' ); // Office Documents, Spreadsheets (office formats possibly containing apples, scripts, etc)
107 define( 'MEDIATYPE_TEXT', 'TEXT' ); // Plain text (possibly containing program code or scripts)
108 define( 'MEDIATYPE_EXECUTABLE', 'EXECUTABLE' ); // binary executable
109 define( 'MEDIATYPE_ARCHIVE', 'ARCHIVE' ); // archive file (zip, tar, etc)
110 /**#@-*/
111
112 /**#@+
113 * Antivirus result codes, for use in $wgAntivirusSetup.
114 */
115
116 define( 'AV_NO_VIRUS', 0 ); #scan ok, no virus found
117 define( 'AV_VIRUS_FOUND', 1 ); #virus found!
118 define( 'AV_SCAN_ABORTED', -1 ); #scan aborted, the file is probably imune
119 define( 'AV_SCAN_FAILED', false ); #scan failed (scanner not found or error in scanner)
120 /**#@-*/
121
122 /**#@+
123 * Anti-lock flags
124 * See DefaultSettings.php for a description
125 */
126 define( 'ALF_PRELOAD_LINKS', 1 );
127 define( 'ALF_PRELOAD_EXISTENCE', 2 );
128 define( 'ALF_NO_LINK_LOCK', 4 );
129 /**#@-*/
130
131 ?>