Project

General

Profile

1
<?php
2

    
3
// $Id: index.php 61 2005-09-09 23:36:52Z stefan $
4

    
5
/*
6

    
7
 Website Baker Project <http://www.websitebaker.org/>
8
 Copyright (C) 2004-2005, Ryan Djurovich
9

    
10
 Website Baker is free software; you can redistribute it and/or modify
11
 it under the terms of the GNU General Public License as published by
12
 the Free Software Foundation; either version 2 of the License, or
13
 (at your option) any later version.
14

    
15
 Website Baker is distributed in the hope that it will be useful,
16
 but WITHOUT ANY WARRANTY; without even the implied warranty of
17
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18
 GNU General Public License for more details.
19

    
20
 You should have received a copy of the GNU General Public License
21
 along with Website Baker; if not, write to the Free Software
22
 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
23

    
24
*/
25

    
26
require('../../config.php');
27
require_once(WB_PATH.'/framework/class.admin.php');
28
if(isset($_GET['advanced']) AND $_GET['advanced'] == 'yes') {
29
	$admin = new admin('Settings', 'settings_advanced');
30
} else {
31
	$admin = new admin('Settings', 'settings_basic');
32
}
33

    
34
// Include the WB functions file
35
require_once(WB_PATH.'/framework/functions.php');
36

    
37
// Create new template object
38
$template = new Template(ADMIN_PATH.'/settings');
39
$template->set_file('page', 'template.html');
40
$template->set_block('page', 'main_block', 'main');
41

    
42
// Query current settings in the db, then loop through them and print them
43
$query = "SELECT * FROM ".TABLE_PREFIX."settings";
44
$results = $database->query($query);
45
while($setting = $results->fetchRow()) {
46
	$setting_name = $setting['name'];
47
	$setting_value = htmlspecialchars($admin->strip_slashes_dummy($setting['value']));
48
	switch($setting_name) {
49
		// Website title
50
		case 'title':
51
			$template->set_var('TITLE', $setting_value);
52
		break;
53
		// Website description
54
		case 'description':
55
			$template->set_var('DESCRIPTION', $setting_value);
56
		break;
57
		// Website keywords
58
		case 'keywords':
59
			$template->set_var('KEYWORDS', $setting_value);
60
		break;
61
		// Website header
62
		case 'header':
63
			$template->set_var('HEADER', $setting_value);
64
		break;
65
		// Website header
66
		case 'header':
67
			$template->set_var('HEADER', $setting_value);
68
		break;
69
		// Website footer
70
		case 'footer':
71
			$template->set_var('FOOTER', $setting_value);
72
		break;
73
		// WYSIWYG style
74
		case 'wysiwyg_style':
75
			$template->set_var('WYSIWYG_STYLE', $setting_value);
76
		break;
77
		case 'rename_files_on_upload':
78
			$template->set_var('RENAME_FILES_ON_UPLOAD', $setting_value);
79
		break;
80
	}
81
}
82

    
83
// Query current settings in the db, then loop through them and print them
84
$query = "SELECT * FROM ".TABLE_PREFIX."search WHERE extra = ''";
85
$results = $database->query($query);
86
while($setting = $results->fetchRow()) {
87
	$setting_name = $setting['name'];
88
	$setting_value = htmlspecialchars($admin->strip_slashes_dummy($setting['value']));
89
	switch($setting_name) {
90
		// Search header
91
		case 'header':
92
			$template->set_var('SEARCH_HEADER', $setting_value);
93
		break;
94
		// Search results header
95
		case 'results_header':
96
			$template->set_var('SEARCH_RESULTS_HEADER', $setting_value);
97
		break;
98
		// Search results loop
99
		case 'results_loop':
100
			$template->set_var('SEARCH_RESULTS_LOOP', $setting_value);
101
		break;
102
		// Search results footer
103
		case 'results_footer':
104
			$template->set_var('SEARCH_RESULTS_FOOTER', $setting_value);
105
		break;
106
		// Search no results
107
		case 'no_results':
108
			$template->set_var('SEARCH_NO_RESULTS', $setting_value);
109
		break;
110
		// Search footer
111
		case 'footer':
112
			$template->set_var('SEARCH_FOOTER', $setting_value);
113
		break;
114
		// Search template
115
		case 'template':
116
			$search_template = $setting_value;
117
		break;
118
	}
119
}
120

    
121
// Do the same for settings stored in config file as with ones in db
122
$database_type = '';
123

    
124
// Tell the browser whether or not to show advanced options
125
if(isset($_GET['advanced']) AND $_GET['advanced'] == 'yes') {
126
	$template->set_var('DISPLAY_ADVANCED', '');
127
	$template->set_var('ADVANCED', 'yes');
128
	$template->set_var('ADVANCED_BUTTON', '<< '.$TEXT['HIDE_ADVANCED']);
129
	$template->set_var('ADVANCED_LINK', 'index.php?advanced=no');
130
	$template->set_var('BASIC_FILE_PERMS_ID', 'hide');
131
	$template->set_var('ADVANCED_FILE_PERMS_ID', 'file_perms_box');
132
} else {
133
	$template->set_var('DISPLAY_ADVANCED', 'none');
134
	$template->set_var('ADVANCED', 'no');
135
	$template->set_var('ADVANCED_BUTTON', $TEXT['SHOW_ADVANCED'].' >>');
136
	$template->set_var('ADVANCED_LINK', 'index.php?advanced=yes');
137
	$template->set_var('BASIC_FILE_PERMS_ID', 'file_perms_box');
138
	$template->set_var('ADVANCED_FILE_PERMS_ID', 'hide');
139
}
140

    
141
$template->set_var(array(	
142
									'PAGE_EXTENSION' => PAGE_EXTENSION,
143
									'PAGE_SPACER' => PAGE_SPACER,
144
									'WB_PATH' => WB_PATH,
145
									'WB_URL' => WB_URL,
146
									'ADMIN_PATH' => ADMIN_PATH,
147
									'ADMIN_URL' => ADMIN_URL,
148
									'DATABASE_TYPE' => DB_TYPE,
149
									'DATABASE_HOST' => DB_HOST,
150
									'DATABASE_USERNAME' => DB_USERNAME,
151
									'DATABASE_NAME' => DB_NAME,
152
									'TABLE_PREFIX' => TABLE_PREFIX
153
								 )
154
						 );
155

    
156
// Insert groups into signup list
157
$template->set_block('main_block', 'group_list_block', 'group_list');
158
$results = $database->query("SELECT group_id, name FROM ".TABLE_PREFIX."groups WHERE group_id != '1'");
159
if($results->numRows() > 0) {
160
	while($group = $results->fetchRow()) {
161
		$template->set_var('ID', $group['group_id']);
162
		$template->set_var('NAME', $group['name']);
163
		if(FRONTEND_SIGNUP == $group['group_id']) {
164
			$template->set_var('SELECTED', 'selected');
165
		} else {
166
			$template->set_var('SELECTED', '');
167
		}
168
		$template->parse('group_list', 'group_list_block', true);
169
	}
170
} else {
171
	$template->set_var('ID', 'disabled');
172
	$template->set_var('NAME', $MESSAGE['GROUPS']['NO_GROUPS_FOUND']);
173
	$template->parse('group_list', 'group_list_block', true);
174
}
175

    
176
// Insert language values
177
$template->set_block('main_block', 'language_list_block', 'language_list');
178
if($handle = opendir(WB_PATH.'/languages/')) {
179
   while (false !== ($file = readdir($handle))) {
180
		if($file != '.' AND $file != '..' AND !is_dir($file) AND $file != 'index.php') {
181
			// Get language name
182
			require(WB_PATH.'/languages/'.$file);
183
			// Insert code and name
184
			$template->set_var(array(
185
											'CODE' => $language_code,
186
											'NAME' => $language_name
187
											)
188
									);
189
			// Check if it is selected
190
			if(DEFAULT_LANGUAGE == $language_code) {
191
				$template->set_var('SELECTED', ' selected');
192
			} else {
193
				$template->set_var('SELECTED', '');
194
			}
195
			$template->parse('language_list', 'language_list_block', true);
196
		}
197
	}
198
	// Restore language to original file
199
	require(WB_PATH.'/languages/'.LANGUAGE.'.php');
200
}
201

    
202
// Insert default timezone values
203
require(ADMIN_PATH.'/interface/timezones.php');
204
$template->set_block('main_block', 'timezone_list_block', 'timezone_list');
205
foreach($TIMEZONES AS $hour_offset => $title) {
206
	// Make sure we dont list "System Default" as we are setting this value!
207
	if($hour_offset != '-20') {
208
		$template->set_var('VALUE', $hour_offset);
209
		$template->set_var('NAME', $title);
210
		if(DEFAULT_TIMEZONE == $hour_offset*60*60) {
211
			$template->set_var('SELECTED', 'selected');
212
		} else {
213
			$template->set_var('SELECTED', '');
214
		}
215
		$template->parse('timezone_list', 'timezone_list_block', true);
216
	}
217
}
218

    
219
// Insert date format list
220
require(ADMIN_PATH.'/interface/date_formats.php');
221
$template->set_block('main_block', 'date_format_list_block', 'date_format_list');
222
foreach($DATE_FORMATS AS $format => $title) {
223
	$format = str_replace('|', ' ', $format); // Add's white-spaces (not able to be stored in array key)
224
	if($format != 'system_default') {
225
		$template->set_var('VALUE', $format);
226
	} else {
227
		$template->set_var('VALUE', '');
228
	}
229
	$template->set_var('NAME', $title);
230
	if(DEFAULT_DATE_FORMAT == $format) {
231
		$template->set_var('SELECTED', 'selected');
232
	} else {
233
		$template->set_var('SELECTED', '');
234
	}
235
	$template->parse('date_format_list', 'date_format_list_block', true);
236
}
237

    
238
// Insert time format list
239
require(ADMIN_PATH.'/interface/time_formats.php');
240
$template->set_block('main_block', 'time_format_list_block', 'time_format_list');
241
foreach($TIME_FORMATS AS $format => $title) {
242
	$format = str_replace('|', ' ', $format); // Add's white-spaces (not able to be stored in array key)
243
	if($format != 'system_default') {
244
		$template->set_var('VALUE', $format);
245
	} else {
246
		$template->set_var('VALUE', '');
247
	}
248
	$template->set_var('NAME', $title);
249
	if(DEFAULT_TIME_FORMAT == $format) {
250
		$template->set_var('SELECTED', 'selected');
251
	} else {
252
		$template->set_var('SELECTED', '');
253
	}
254
	$template->parse('time_format_list', 'time_format_list_block', true);
255
}
256

    
257
// Insert templates
258
$template->set_block('main_block', 'template_list_block', 'template_list');
259
if($handle = opendir(WB_PATH.'/templates/')) {
260
	while (false !== ($file = readdir($handle))) {
261
		if($file != "." AND $file != ".." AND $file != ".svn" AND is_dir(WB_PATH."/templates/$file") AND file_exists(WB_PATH."/templates/$file/info.php")) {
262
			include(WB_PATH."/templates/$file/info.php");
263
			$template->set_var('FILE', $file);
264
			$template->set_var('NAME', $template_name);
265
			if($file == DEFAULT_TEMPLATE ? $selected = ' selected' : $selected = '');
266
			$template->set_var('SELECTED', $selected);
267
			$template->parse('template_list', 'template_list_block', true);
268
		}
269
	}
270
}
271

    
272
// Insert templates
273
$template->set_block('main_block', 'editor_list_block', 'editor_list');
274
$file='htmlarea';
275
$module_name='HTMLArea';
276
$template->set_var('FILE', $file);
277
$template->set_var('NAME', $module_name);
278
if((!defined('WYSIWYG_EDITOR') OR $file == WYSIWYG_EDITOR) ? $selected = ' selected' : $selected = '');
279
$template->set_var('SELECTED', $selected);
280
$template->parse('editor_list', 'editor_list_block', true);
281
if($handle = opendir(WB_PATH.'/modules/')) {
282
	while (false !== ($file = readdir($handle))) {
283
		if($file != "." AND $file != ".." AND $file != "CVS" AND is_dir(WB_PATH."/modules/$file") AND file_exists(WB_PATH."/modules/$file/info.php")) {
284
			include(WB_PATH."/modules/$file/info.php");
285
			if ($module_type == 'WYSIWYG') {
286
				$template->set_var('FILE', $file);
287
				$template->set_var('NAME', $module_name);
288
				if((defined('WYSIWYG_EDITOR') AND $file == WYSIWYG_EDITOR) ? $selected = ' selected' : $selected = '');
289
				$template->set_var('SELECTED', $selected);
290
				$template->parse('editor_list', 'editor_list_block', true);
291
			}
292
		}
293
	}
294
}
295

    
296

    
297
// Insert templates for search settings
298
$template->set_block('main_block', 'search_template_list_block', 'search_template_list');
299
if($search_template == '') { $selected = ' selected'; } else { $selected = ''; }
300
$template->set_var(array('FILE' => '', 'NAME' => $TEXT['SYSTEM_DEFAULT'], 'SELECTED' => $selected));
301
$template->parse('search_template_list', 'search_template_list_block', true);
302
if($handle = opendir(WB_PATH.'/templates/')) {
303
	while (false !== ($file = readdir($handle))) {
304
		if($file != "." AND $file != ".." AND $file != ".svn" AND is_dir(WB_PATH."/templates/$file") AND file_exists(WB_PATH."/templates/$file/info.php")) {
305
			include(WB_PATH."/templates/$file/info.php");
306
			$template->set_var('FILE', $file);
307
			$template->set_var('NAME', $template_name);
308
			if($file == $search_template ? $selected = ' selected' : $selected = '');
309
			$template->set_var('SELECTED', $selected);
310
			$template->parse('search_template_list', 'search_template_list_block', true);
311
		}
312
	}
313
}
314

    
315
// Insert default error reporting values
316
require(ADMIN_PATH.'/interface/er_levels.php');
317
$template->set_block('main_block', 'error_reporting_list_block', 'error_reporting_list');
318
foreach($ER_LEVELS AS $value => $title) {
319
	$template->set_var('VALUE', $value);
320
	$template->set_var('NAME', $title);
321
	if(ER_LEVEL == $value) {
322
		$template->set_var('SELECTED', 'selected');
323
	} else {
324
		$template->set_var('SELECTED', '');
325
	}
326
	$template->parse('error_reporting_list', 'error_reporting_list_block', true);
327
}
328

    
329
// Insert permissions values
330
if($admin->get_permission('settings_advanced') != true) {
331
	$template->set_var('DISPLAY_ADVANCED_BUTTON', 'hide');
332
}
333

    
334
// Insert page level limits
335
$template->set_block('main_block', 'page_level_limit_list_block', 'page_level_limit_list');
336
for($i = 1; $i <= 10; $i++) {
337
	$template->set_var('NUMBER', $i);
338
	if(PAGE_LEVEL_LIMIT == $i) {
339
		$template->set_var('SELECTED', 'selected');
340
	} else {
341
		$template->set_var('SELECTED', '');
342
	}
343
	$template->parse('page_level_limit_list', 'page_level_limit_list_block', true);
344
}
345

    
346
// Work-out if multiple menus feature is enabled
347
if(defined('MULTIPLE_MENUS') AND MULTIPLE_MENUS == true) {
348
	$template->set_var('MULTIPLE_MENUS_ENABLED', ' checked');
349
} else {
350
	$template->set_var('MULTIPLE_MENUS_DISABLED', ' checked');
351
}
352

    
353
// Work-out if page languages feature is enabled
354
if(defined('PAGE_LANGUAGES') AND PAGE_LANGUAGES == true) {
355
	$template->set_var('PAGE_LANGUAGES_ENABLED', ' checked');
356
} else {
357
	$template->set_var('PAGE_LANGUAGES_DISABLED', ' checked');
358
}
359

    
360
// Work-out if smart login feature is enabled
361
if(defined('SMART_LOGIN') AND SMART_LOGIN == true) {
362
	$template->set_var('SMART_LOGIN_ENABLED', ' checked');
363
} else {
364
	$template->set_var('SMART_LOGIN_DISABLED', ' checked');
365
}
366

    
367
// Work-out if section blocks feature is enabled
368
if(defined('SECTION_BLOCKS') AND SECTION_BLOCKS == true) {
369
	$template->set_var('SECTION_BLOCKS_ENABLED', ' checked');
370
} else {
371
	$template->set_var('SECTION_BLOCKS_DISABLED', ' checked');
372
}
373

    
374
// Work-out if homepage redirection feature is enabled
375
if(defined('HOMEPAGE_REDIRECTION') AND HOMEPAGE_REDIRECTION == true) {
376
	$template->set_var('HOMEPAGE_REDIRECTION_ENABLED', ' checked');
377
} else {
378
	$template->set_var('HOMEPAGE_REDIRECTION_DISABLED', ' checked');
379
}
380

    
381
// Work-out which server os should be checked
382
if(OPERATING_SYSTEM == 'linux') {
383
	$template->set_var('LINUX_SELECTED', ' checked');
384
} elseif(OPERATING_SYSTEM == 'windows') {
385
	$template->set_var('WINDOWS_SELECTED', ' checked');
386
}
387

    
388
// Work-out if manage sections feature is enabled
389
if(MANAGE_SECTIONS) {
390
	$template->set_var('MANAGE_SECTIONS_ENABLED', ' checked');
391
} else {
392
	$template->set_var('MANAGE_SECTIONS_DISABLED', ' checked');
393
}
394

    
395
// Work-out if intro feature is enabled
396
if(INTRO_PAGE) {
397
	$template->set_var('INTRO_PAGE_ENABLED', ' checked');
398
} else {
399
	$template->set_var('INTRO_PAGE_DISABLED', ' checked');
400
}
401

    
402
// Work-out if frontend login feature is enabled
403
if(FRONTEND_LOGIN) {
404
	$template->set_var('PRIVATE_ENABLED', ' checked');
405
} else {
406
	$template->set_var('PRIVATE_DISABLED', ' checked');
407
}
408

    
409
// Work-out if page trash feature is disabled, in-line, or separate
410
if(PAGE_TRASH == 'disabled') {
411
	$template->set_var('PAGE_TRASH_DISABLED', ' checked');
412
} elseif(PAGE_TRASH == 'inline') {
413
	$template->set_var('PAGE_TRASH_INLINE', ' checked');
414
} elseif(PAGE_TRASH == 'separate') {
415
	$template->set_var('PAGE_TRASH_SEPARATE', ' checked');
416
}
417

    
418
// Work-out if media home folde feature is enabled
419
if(HOME_FOLDERS) {
420
	$template->set_var('HOME_FOLDERS_ENABLED', ' checked');
421
} else {
422
	$template->set_var('HOME_FOLDERS_DISABLED', ' checked');
423
}
424

    
425
// Insert search select
426
if(SEARCH == 'private') {
427
	$template->set_var('PRIVATE_SEARCH', 'selected');
428
} elseif(SEARCH == 'registered') {
429
	$template->set_var('REGISTERED_SEARCH', 'selected');
430
} elseif(SEARCH == 'none') {
431
	$template->set_var('NONE_SEARCH', 'selected');
432
}
433

    
434
// Work-out if 777 permissions are set
435
if(STRING_FILE_MODE == '0777' AND STRING_DIR_MODE == '0777') {
436
	$template->set_var('WORLD_WRITEABLE_SELECTED', ' checked');
437
}
438

    
439
// Work-out which file mode boxes are checked
440
if(extract_permission(STRING_FILE_MODE, 'u', 'r')) {
441
	$template->set_var('FILE_U_R_CHECKED', 'checked');
442
}
443
if(extract_permission(STRING_FILE_MODE, 'u', 'w')) {
444
	$template->set_var('FILE_U_W_CHECKED', 'checked');
445
}
446
if(extract_permission(STRING_FILE_MODE, 'u', 'e')) {
447
	$template->set_var('FILE_U_E_CHECKED', 'checked');
448
}
449
if(extract_permission(STRING_FILE_MODE, 'g', 'r')) {
450
	$template->set_var('FILE_G_R_CHECKED', 'checked');
451
}
452
if(extract_permission(STRING_FILE_MODE, 'g', 'w')) {
453
	$template->set_var('FILE_G_W_CHECKED', 'checked');
454
}
455
if(extract_permission(STRING_FILE_MODE, 'g', 'e')) {
456
	$template->set_var('FILE_G_E_CHECKED', 'checked');
457
}
458
if(extract_permission(STRING_FILE_MODE, 'o', 'r')) {
459
	$template->set_var('FILE_O_R_CHECKED', 'checked');
460
}
461
if(extract_permission(STRING_FILE_MODE, 'o', 'w')) {
462
	$template->set_var('FILE_O_W_CHECKED', 'checked');
463
}
464
if(extract_permission(STRING_FILE_MODE, 'o', 'e')) {
465
	$template->set_var('FILE_O_E_CHECKED', 'checked');
466
}
467
// Work-out which dir mode boxes are checked
468
if(extract_permission(STRING_DIR_MODE, 'u', 'r')) {
469
	$template->set_var('DIR_U_R_CHECKED', 'checked');
470
}
471
if(extract_permission(STRING_DIR_MODE, 'u', 'w')) {
472
	$template->set_var('DIR_U_W_CHECKED', 'checked');
473
}
474
if(extract_permission(STRING_DIR_MODE, 'u', 'e')) {
475
	$template->set_var('DIR_U_E_CHECKED', 'checked');
476
}
477
if(extract_permission(STRING_DIR_MODE, 'g', 'r')) {
478
	$template->set_var('DIR_G_R_CHECKED', 'checked');
479
}
480
if(extract_permission(STRING_DIR_MODE, 'g', 'w')) {
481
	$template->set_var('DIR_G_W_CHECKED', 'checked');
482
}
483
if(extract_permission(STRING_DIR_MODE, 'g', 'e')) {
484
	$template->set_var('DIR_G_E_CHECKED', 'checked');
485
}
486
if(extract_permission(STRING_DIR_MODE, 'o', 'r')) {
487
	$template->set_var('DIR_O_R_CHECKED', 'checked');
488
}
489
if(extract_permission(STRING_DIR_MODE, 'o', 'w')) {
490
	$template->set_var('DIR_O_W_CHECKED', 'checked');
491
}
492
if(extract_permission(STRING_DIR_MODE, 'o', 'e')) {
493
	$template->set_var('DIR_O_E_CHECKED', 'checked');
494
}
495

    
496
// Insert Server Email value into template
497
$template->set_var('SERVER_EMAIL', SERVER_EMAIL);
498

    
499
// Insert language headings
500
$template->set_var(array(
501
								'HEADING_GENERAL_SETTINGS' => $HEADING['GENERAL_SETTINGS'],
502
								'HEADING_DEFAULT_SETTINGS' => $HEADING['DEFAULT_SETTINGS'],
503
								'HEADING_SEARCH_SETTINGS' => $HEADING['SEARCH_SETTINGS'],
504
								'HEADING_FILESYSTEM_SETTINGS' => $HEADING['FILESYSTEM_SETTINGS']
505
								)
506
						);
507
// Insert language text and messages
508
$template->set_var(array(
509
								'TEXT_WEBSITE_TITLE' => $TEXT['WEBSITE_TITLE'],
510
								'TEXT_WEBSITE_DESCRIPTION' => $TEXT['WEBSITE_DESCRIPTION'],
511
								'TEXT_WEBSITE_KEYWORDS' => $TEXT['WEBSITE_KEYWORDS'],
512
								'TEXT_WEBSITE_HEADER' => $TEXT['WEBSITE_HEADER'],
513
								'TEXT_WEBSITE_FOOTER' => $TEXT['WEBSITE_FOOTER'],
514
								'TEXT_HEADER' => $TEXT['HEADER'],
515
								'TEXT_FOOTER' => $TEXT['FOOTER'],
516
								'TEXT_VISIBILITY' => $TEXT['VISIBILITY'],
517
								'TEXT_RESULTS_HEADER' => $TEXT['RESULTS_HEADER'],
518
								'TEXT_RESULTS_LOOP' => $TEXT['RESULTS_LOOP'],
519
								'TEXT_RESULTS_FOOTER' => $TEXT['RESULTS_FOOTER'],
520
								'TEXT_NO_RESULTS' => $TEXT['NO_RESULTS'],
521
								'TEXT_TEXT' => $TEXT['TEXT'],
522
								'TEXT_DEFAULT' => $TEXT['DEFAULT'],
523
								'TEXT_LANGUAGE' => $TEXT['LANGUAGE'],
524
								'TEXT_TIMEZONE' => $TEXT['TIMEZONE'],
525
								'TEXT_DATE_FORMAT' => $TEXT['DATE_FORMAT'],
526
								'TEXT_TIME_FORMAT' => $TEXT['TIME_FORMAT'],
527
								'TEXT_TEMPLATE' => $TEXT['TEMPLATE'],
528
								'TEXT_EDITOR' => $TEXT['WYSIWYG_EDITOR'],
529
								'TEXT_PAGE_LEVEL_LIMIT' => $TEXT['PAGE_LEVEL_LIMIT'],
530
								'TEXT_INTRO_PAGE' => $TEXT['INTRO_PAGE'],
531
								'TEXT_FRONTEND' => $TEXT['FRONTEND'],
532
								'TEXT_LOGIN' => $TEXT['LOGIN'],
533
								'TEXT_SIGNUP' => $TEXT['SIGNUP'],
534
								'TEXT_PHP_ERROR_LEVEL' => $TEXT['PHP_ERROR_LEVEL'],
535
								'TEXT_PAGE_EXTENSION' => $TEXT['PAGE_EXTENSION'],
536
								'TEXT_PAGE_SPACER' => $TEXT['PAGE_SPACER'],
537
								'TEXT_RENAME_FILES_ON_UPLOAD' => $TEXT['RENAME_FILES_ON_UPLOAD'],
538
								'TEXT_SERVER_OPERATING_SYSTEM' => $TEXT['SERVER_OPERATING_SYSTEM'],
539
								'TEXT_LINUX_UNIX_BASED' => $TEXT['LINUX_UNIX_BASED'],
540
								'TEXT_WINDOWS' => $TEXT['WINDOWS'],
541
								'TEXT_ADMIN' => $TEXT['ADMIN'],
542
								'TEXT_TYPE' => $TEXT['TYPE'],
543
								'TEXT_DATABASE' => $TEXT['DATABASE'],
544
								'TEXT_HOST' => $TEXT['HOST'],
545
								'TEXT_USERNAME' => $TEXT['USERNAME'],
546
								'TEXT_PASSWORD' => $TEXT['PASSWORD'],
547
								'TEXT_NAME' => $TEXT['NAME'],
548
								'TEXT_TABLE_PREFIX' => $TEXT['TABLE_PREFIX'],
549
								'TEXT_SAVE' => $TEXT['SAVE'],
550
								'TEXT_RESET' => $TEXT['RESET'],
551
								'TEXT_CHANGES' => $TEXT['CHANGES'],
552
								'TEXT_ENABLED' => $TEXT['ENABLED'],
553
								'TEXT_DISABLED' => $TEXT['DISABLED'],
554
								'TEXT_MANAGE_SECTIONS' => $HEADING['MANAGE_SECTIONS'],
555
								'TEXT_MANAGE' => $TEXT['MANAGE'],
556
								'TEXT_SEARCH' => $TEXT['SEARCH'],
557
								'TEXT_PUBLIC' => $TEXT['PUBLIC'],
558
								'TEXT_PRIVATE' => $TEXT['PRIVATE'],
559
								'TEXT_REGISTERED' => $TEXT['REGISTERED'],
560
								'TEXT_NONE' => $TEXT['NONE'],
561
								'TEXT_FILES' => strtoupper(substr($TEXT['FILES'], 0, 1)).substr($TEXT['FILES'], 1),
562
								'TEXT_DIRECTORIES' => $TEXT['DIRECTORIES'],
563
								'TEXT_FILESYSTEM_PERMISSIONS' => $TEXT['FILESYSTEM_PERMISSIONS'],
564
								'TEXT_USER' => $TEXT['USER'],
565
								'TEXT_GROUP' => $TEXT['GROUP'],
566
								'TEXT_OTHERS' => $TEXT['OTHERS'],
567
								'TEXT_READ' => $TEXT['READ'],
568
								'TEXT_WRITE' => $TEXT['WRITE'],
569
								'TEXT_EXECUTE' => $TEXT['EXECUTE'],
570
								'TEXT_SMART_LOGIN' => $TEXT['SMART_LOGIN'],
571
								'TEXT_MULTIPLE_MENUS' => $TEXT['MULTIPLE_MENUS'],
572
								'TEXT_HOMEPAGE_REDIRECTION' => $TEXT['HOMEPAGE_REDIRECTION'],
573
								'TEXT_PAGE_LANGUAGES' => $TEXT['PAGE_LANGUAGES'],
574
								'TEXT_SECTION_BLOCKS' => $TEXT['SECTION_BLOCKS'],
575
								'TEXT_PLEASE_SELECT' => $TEXT['PLEASE_SELECT'],
576
								'TEXT_PAGE_TRASH' => $TEXT['PAGE_TRASH'],
577
								'TEXT_INLINE' => $TEXT['INLINE'],
578
								'TEXT_SEPARATE' => $TEXT['SEPARATE'],
579
								'TEXT_HOME_FOLDERS' => $TEXT['HOME_FOLDERS'],
580
								'TEXT_WYSIWYG_STYLE' => $TEXT['WYSIWYG_STYLE'],
581
								'TEXT_SERVER_EMAIL' => $TEXT['SERVER_EMAIL'],
582
								'TEXT_WORLD_WRITEABLE_FILE_PERMISSIONS' => $TEXT['WORLD_WRITEABLE_FILE_PERMISSIONS'],
583
								'MODE_SWITCH_WARNING' => $MESSAGE['SETTINGS']['MODE_SWITCH_WARNING'],
584
								'WORLD_WRITEABLE_WARNING' => $MESSAGE['SETTINGS']['WORLD_WRITEABLE_WARNING']
585
								)
586
						);
587

    
588
// Parse template objects output
589
$template->parse('main', 'main_block', false);
590
$template->pparse('output', 'page');
591

    
592
$admin->print_footer();
593

    
594
?>
(1-1/3)