forked from pgBoard/pgBoard
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.default.php
190 lines (171 loc) · 8.02 KB
/
config.default.php
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
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
<?php
define("LANG","en");
define("ADMIN_EMAIL","[email protected]");
define("DB","dbname=board user=board password=board");
define("DIR","/path/to/board/www/");
define("SPHINX_HOST","localhost");
define("SPHINX_PORT",3312);
define("REGISTRATION_OPEN",true);
define("REGISTRATION_PASSWORD","membersonly"); // set to false to disable this feature
define("MEMBER_REGEXP","^[a-z0-9_-]{3,15}$"); // regexp to define valid member name
define("IGNORE_ENABLED",true); // if you disable this be sure to DELETE * FROM member_ignore
define("IGNORE_PUBLIC",true); // set to false to make ignoring private
define("IGNORE_BUFFER","1 year"); // how long from first post until ignore can be used (set false to disable)
define("IGNORED_THREADS_PUBLIC",true); // set to false to make thread ignoring private
define("FAVORITES_PUBLIC",true); // set to false to make favorite threads private
define("LIST_DEFAULT_LIMIT",100); // number of threads per page
define("COLLAPSE_DEFAULT",25); // default value to collapse at
define("COLLAPSE_OPEN_DEFAULT",5); // default number of posts to leave open after collapse
define("UNCOLLAPSE_COUNT_DEFAULT",15); // number of additional posts to show when showing "more"
define("FUNDRAISER_ID",-1); // id of fundraiser record in database
define("FUNDRAISER_ITEM_NAME","Board Hosting"); // item name for paypal ipn to recognize payment
define("FUNDRAISER_EMAIL","[email protected]"); // email address for paypal payments
define("VIEW_DATE_FORMAT","F jS, Y @ g:i:s a");
define("LIST_DATE_FORMAT","D\&\\n\b\s\p\;M\&\\n\b\s\p\;d\&\\n\b\s\p;Y&\\n\b\s\p\;h:i\&\\n\b\s\p\;a");
define("FORM_SALT","aksjdsa9*^&*@&(@*22@*1");
// functions allowed no matter what your login state
$_allowed_ = array("threadmain","threadlist","threadview","threadviewpost",
"threadfirstpost","threadreply","threadpreviewpost",
"threadtogglefavorite","mainlogin","mainchangelog","donatemain",
"donateaccept","membercreate","memberauthorize");
// menu display
$_menu_ = array("create account" => array("link" => "/member/create/",
"title" => "create an account",
"code" => "",
"show" => REGISTRATION_OPEN,
"auth" => false),
"threads" => array("title" => "back to the home page",
"link" => "/",
"code" => "",
"show" => true,
"auth" => false),
"messages%MESSAGES%" => array("link" => "/message/list/",
"title" => "view your messages",
"code" => "",
"show" => true,
"auth" => true),
"new thread" => array("link" => "/thread/create/",
"title" => "create a new thread",
"code" => "",
"show" => true,
"auth" => true),
"new message" => array("link" => "/message/create/",
"title" => "send a message to another member",
"code" => "",
"show" => true,
"auth" => true),
"search" => array("link" => "/search/",
"title"=> "search the board",
"code" => "",
"show" => true,
"auth" => true),
"chat%CHATTERS%" => array("link" => "/chat/",
"title" => "chat in realtime",
"code" => "",
"show" => true,
"auth" => true),
"profile" => array("link" => "/member/view/",
"title" => "view my profile",
"code" => "",
"show" => true,
"auth" => true),
"donate" => array("link" => "/donate/",
"title" => "donate!",
"code" => "",
"show" => true,
"auth" => false));
// parser find
$_bbc_ = array("","[u]","[/u]",
"[i]","[/i]",
"[em]","[/em]",
"[quote]","[/quote]",
"[b]","[/b]",
"[strong]","[/strong]",
"[strike]","[/strike]",
"[code]","[/code]",
"[sub]","[/sub]",
"[sup]","[/sup]",
"[spoiler]","[/spoiler]");
// parser replace
$_rep_ = array("","<span style=\"text-decoration:underline;\">","</span>",
"<em>","</em>",
"<em>","</em>",
"<blockquote>","</blockquote>",
"<strong>","</strong>",
"<strong>","</strong>",
"<strike>","</strike>",
"<pre>","</pre><div class=clear></div>",
"<sub>","</sub>",
"<sup>","</sup>",
"<span class=\"spoiler\" onclick=\"$(this).next().show();$(this).remove()\">show spoiler</span><span style=\"display:none\">","</span>");
/*
* Do not edit below this line unless you know what you're doing!
**/
define("VERSION","2.9.5");
require_once("core.php"); // framework
ini_set("magic_gpc_quotes",false);
if(module(0) == "main" && !cmd(1))
{
set_cmd(0,"thread");
set_cmd(1,"list");
}
if(!isset($commandline))
{
$cache = array(); // no caching for the moment array("threadview","messageview");
if(!in_array(module(0).func(),$cache))
{
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache");
}
else
session_cache_limiter("private");
session_start();
}
require_once("error.php"); // error handler
require_once("lang/".LANG.".php"); // language file
require_once("class/Security.php"); // security
require_once("class/Core.php"); // common commands
require_once("class/DB.php"); // database
require_once("class/Query.php"); // query creation
require_once("class/Style.php"); // color themes, dynamic styling
require_once("class/Base.php"); // base layout
require_once("class/List.php"); // display for lists
require_once("class/View.php"); // display for views
require_once("class/Parse.php"); // bbcode parser
require_once("class/Form.php"); // forms
require_once("class/Data.php"); // data management
require_once("class/Search.php"); // search management
require_once("class/Admin.php"); // search management
require_once("class/Plugin.php"); // plugins
$Security = new BoardSecurity;
$Core = new BoardCore;
$DB = new DB(DB,true);
$Parse = new BoardParse($_bbc_,$_rep_);
if(!session('id') && cookie('board')) $Security->login_cookie();
$Style = new BoardStyle(session('id'));
if(!isset($commandline))
{
ob_start();
if(!$DB->db)
{
$Base = new Base;
$Base->title("Dead database!");
$Base->header();
$Base->footer();
}
else
{
$Core->command_parse();
if(get('ajax'))
{
$buffer = ob_get_contents();
ob_end_clean();
print $buffer;
exit_clean();
}
$buffer = ob_get_contents();
ob_end_clean();
}
}