1 |
1356
|
Luisehahne
|
<?php
|
2 |
|
|
/**
|
3 |
|
|
*
|
4 |
|
|
* @category admin
|
5 |
|
|
* @package settings
|
6 |
1529
|
Luisehahne
|
* @author Ryan Djurovich, WebsiteBaker Project
|
7 |
1716
|
Luisehahne
|
* @copyright 2009-2012, WebsiteBaker Org. e.V.
|
8 |
1843
|
Luisehahne
|
* @link http://www.websitebaker2.org/
|
9 |
1356
|
Luisehahne
|
* @license http://www.gnu.org/licenses/gpl.html
|
10 |
|
|
* @platform WebsiteBaker 2.8.x
|
11 |
1374
|
Luisehahne
|
* @requirements PHP 5.2.2 and higher
|
12 |
1356
|
Luisehahne
|
* @version $Id$
|
13 |
1843
|
Luisehahne
|
* @filesource $HeadURL$
|
14 |
1356
|
Luisehahne
|
* @lastmodified $Date$
|
15 |
|
|
*
|
16 |
|
|
*/
|
17 |
|
|
|
18 |
1843
|
Luisehahne
|
// Include config file
|
19 |
|
|
if(!defined('WB_URL'))
|
20 |
|
|
{
|
21 |
|
|
$config_file = realpath('../../config.php');
|
22 |
|
|
if(file_exists($config_file) && !defined('WB_URL'))
|
23 |
|
|
{
|
24 |
|
|
require($config_file);
|
25 |
|
|
}
|
26 |
|
|
}
|
27 |
|
|
if(!class_exists('admin', false)){ include(WB_PATH.'/framework/class.admin.php'); }
|
28 |
1356
|
Luisehahne
|
|
29 |
|
|
if(isset($_GET['advanced']) && $_GET['advanced'] == 'yes') {
|
30 |
|
|
$admin = new admin('Settings', 'settings_advanced');
|
31 |
|
|
} else {
|
32 |
|
|
$admin = new admin('Settings', 'settings_basic');
|
33 |
|
|
}
|
34 |
|
|
|
35 |
1716
|
Luisehahne
|
// add new values, later in upgrade-script
|
36 |
|
|
$cfg = array(
|
37 |
1844
|
Luisehahne
|
'wbmail_signature' => defined('WBMAIL_SIGNATURE') ? WBMAIL_SIGNATURE : '',
|
38 |
1716
|
Luisehahne
|
'confirmed_registration' => (defined('CONFIRMED_REGISTRATION') ? CONFIRMED_REGISTRATION : '0'),
|
39 |
1767
|
Luisehahne
|
'modules_upgrade_list' => (defined('MODULES_UPGRADE_LIST') ? MODULES_UPGRADE_LIST : ''),
|
40 |
1849
|
Luisehahne
|
'page_extendet' => (defined('PAGE_EXTENDET') ? PAGE_EXTENDET : 'true'),
|
41 |
1716
|
Luisehahne
|
);
|
42 |
|
|
db_update_key_value( 'settings', $cfg );
|
43 |
|
|
|
44 |
1356
|
Luisehahne
|
// Include the WB functions file
|
45 |
|
|
require_once(WB_PATH.'/framework/functions.php');
|
46 |
|
|
require_once(WB_PATH.'/framework/functions-utf8.php');
|
47 |
|
|
|
48 |
1777
|
Luisehahne
|
if(!class_exists('Template', false)){ include(WB_PATH.'/include/phplib/ttemplate.inc'); }
|
49 |
1716
|
Luisehahne
|
|
50 |
1529
|
Luisehahne
|
// Setup template object, parse vars to it, then parse it
|
51 |
1356
|
Luisehahne
|
// Create new template object
|
52 |
1777
|
Luisehahne
|
$oTpl = new Template(dirname($admin->correct_theme_source('settings.htt')),'comment');
|
53 |
|
|
//$oTpl->debug = true;
|
54 |
|
|
//$oTpl->filename_comments = true;
|
55 |
|
|
//$oTpl->unknown_regexp = "strict";
|
56 |
|
|
//$oTpl->halt_on_error = "report" ;
|
57 |
1356
|
Luisehahne
|
|
58 |
1777
|
Luisehahne
|
$oTpl->set_file('page', 'settings.htt');
|
59 |
|
|
$oTpl->set_block('page', 'main_block', 'main');
|
60 |
1356
|
Luisehahne
|
|
61 |
1777
|
Luisehahne
|
$mLang = ModLanguage::getInstance();
|
62 |
|
|
$mLang->setLanguage(dirname(__FILE__).'/languages/', LANGUAGE, DEFAULT_LANGUAGE);
|
63 |
|
|
|
64 |
|
|
$oTpl->set_var('FTAN', $admin->getFTAN());
|
65 |
1745
|
Luisehahne
|
/*-- insert all needed vars from language files ----------------------------------------*/
|
66 |
1777
|
Luisehahne
|
$oTpl->set_var($mLang->getLangArray());
|
67 |
1356
|
Luisehahne
|
|
68 |
|
|
// Query current settings in the db, then loop through them and print them
|
69 |
1777
|
Luisehahne
|
$query = "SELECT * FROM `".TABLE_PREFIX."settings`";
|
70 |
|
|
if($results = $database->query($query)) {
|
71 |
|
|
while($setting = $results->fetchRow(MYSQL_ASSOC)) {
|
72 |
|
|
$setting_name = $setting['name'];
|
73 |
|
|
$setting_value = ( $setting_name != 'wbmailer_smtp_password' ) ? htmlspecialchars($setting['value']) : htmlentities($setting['value'], ENT_COMPAT, 'UTF-8');
|
74 |
|
|
$oTpl->set_var(strtoupper($setting_name),($setting_value));
|
75 |
|
|
}
|
76 |
1356
|
Luisehahne
|
}
|
77 |
|
|
|
78 |
|
|
$is_advanced = (isset($_GET['advanced']) && $_GET['advanced'] == 'yes');
|
79 |
|
|
// Tell the browser whether or not to show advanced options
|
80 |
1777
|
Luisehahne
|
if($is_advanced)
|
81 |
|
|
{
|
82 |
|
|
$oTpl->set_var('DISPLAY_ADVANCED', '');
|
83 |
|
|
$oTpl->set_var('ADVANCED_FILE_PERMS_ID', 'file_perms_box');
|
84 |
|
|
$oTpl->set_var('BASIC_FILE_PERMS_ID', 'hide');
|
85 |
|
|
$oTpl->set_var('ADVANCED', 'yes');
|
86 |
|
|
$oTpl->set_var('ADVANCED_BUTTON', '<< '.$TEXT['HIDE_ADVANCED']);
|
87 |
|
|
$oTpl->set_var('ADVANCED_LINK', 'index.php?advanced=no');
|
88 |
1356
|
Luisehahne
|
|
89 |
1777
|
Luisehahne
|
} else {
|
90 |
|
|
$oTpl->set_var('DISPLAY_ADVANCED', ' style="display: none;"');
|
91 |
|
|
$oTpl->set_var('BASIC_FILE_PERMS_ID', 'file_perms_box');
|
92 |
|
|
$oTpl->set_var('ADVANCED_FILE_PERMS_ID', 'hide');
|
93 |
1356
|
Luisehahne
|
|
94 |
1777
|
Luisehahne
|
$oTpl->set_var('ADVANCED', 'no');
|
95 |
|
|
$oTpl->set_var('ADVANCED_BUTTON', $TEXT['SHOW_ADVANCED'].' >>');
|
96 |
|
|
$oTpl->set_var('ADVANCED_LINK', 'index.php?advanced=yes');
|
97 |
|
|
}
|
98 |
1356
|
Luisehahne
|
|
99 |
1777
|
Luisehahne
|
$sSelected = ' selected="selected"';
|
100 |
|
|
$checked = ' checked="checked"';
|
101 |
1356
|
Luisehahne
|
|
102 |
1777
|
Luisehahne
|
$oTpl->set_var(array(
|
103 |
|
|
'WB_URL' => WB_URL,
|
104 |
|
|
'THEME_URL' => THEME_URL,
|
105 |
|
|
'ADMIN_URL' => ADMIN_URL,
|
106 |
|
|
));
|
107 |
|
|
|
108 |
|
|
// Insert language headings
|
109 |
|
|
$oTpl->set_var(array(
|
110 |
|
|
'HEADING_GENERAL_SETTINGS' => $HEADING['GENERAL_SETTINGS'],
|
111 |
|
|
'HEADING_DEFAULT_SETTINGS' => $HEADING['DEFAULT_SETTINGS'],
|
112 |
|
|
'HEADING_SEARCH_SETTINGS' => $HEADING['SEARCH_SETTINGS'],
|
113 |
|
|
'HEADING_SERVER_SETTINGS' => $HEADING['SERVER_SETTINGS'],
|
114 |
|
|
'HEADING_WBMAILER_SETTINGS' => $HEADING['WBMAILER_SETTINGS'],
|
115 |
|
|
'HEADING_ADMINISTRATION_TOOLS' => $HEADING['ADMINISTRATION_TOOLS']
|
116 |
|
|
)
|
117 |
|
|
);
|
118 |
|
|
|
119 |
|
|
// Insert language textarea label
|
120 |
|
|
$oTpl->set_var(array(
|
121 |
|
|
'TEXT_WEBSITE_TITLE' => $TEXT['WEBSITE_TITLE'],
|
122 |
|
|
'TEXT_WEBSITE_DESCRIPTION' => $TEXT['WEBSITE_DESCRIPTION'],
|
123 |
|
|
'TEXT_WEBSITE_KEYWORDS' => $TEXT['WEBSITE_KEYWORDS'],
|
124 |
|
|
'TEXT_WEBSITE_HEADER' => $TEXT['WEBSITE_HEADER'],
|
125 |
|
|
'TEXT_WEBSITE_FOOTER' => $TEXT['WEBSITE_FOOTER'],
|
126 |
|
|
'TEXT_HEADER' => $TEXT['HEADER'],
|
127 |
|
|
'TEXT_FOOTER' => $TEXT['FOOTER'],
|
128 |
|
|
'TEXT_TEXT' => $TEXT['TEXT'],
|
129 |
|
|
'TEXT_RESULTS_HEADER' => $TEXT['RESULTS_HEADER'],
|
130 |
|
|
'TEXT_RESULTS_LOOP' => $TEXT['RESULTS_LOOP'],
|
131 |
|
|
'TEXT_RESULTS_FOOTER' => $TEXT['RESULTS_FOOTER'],
|
132 |
|
|
));
|
133 |
|
|
|
134 |
|
|
// Insert generell language
|
135 |
|
|
$oTpl->set_var(array(
|
136 |
|
|
'TEXT_SAVE' => $TEXT['SAVE'],
|
137 |
|
|
'TEXT_RESET' => $TEXT['RESET'],
|
138 |
|
|
'TEXT_ENABLED' => $TEXT['ENABLED'],
|
139 |
|
|
'TEXT_DISABLED' => $TEXT['DISABLED'],
|
140 |
|
|
'TEXT_DEFAULT' => $TEXT['DEFAULT'],
|
141 |
|
|
'TEXT_NO_RESULTS' => $TEXT['NO_RESULTS'],
|
142 |
|
|
'TEXT_PLEASE_SELECT' => $TEXT['PLEASE_SELECT'],
|
143 |
|
|
));
|
144 |
|
|
|
145 |
|
|
// Insert language labels
|
146 |
|
|
$oTpl->set_var(array(
|
147 |
|
|
'TEXT_PAGE_TRASH' => $TEXT['PAGE_TRASH'],
|
148 |
|
|
'TEXT_PAGE_LANGUAGES' => $TEXT['PAGE_LANGUAGES'],
|
149 |
|
|
'TEXT_FRONTEND' => $TEXT['FRONTEND'],
|
150 |
|
|
'TEXT_LOGIN' => $TEXT['LOGIN'],
|
151 |
|
|
'TEXT_HOMEPAGE_REDIRECTION' => $TEXT['HOMEPAGE_REDIRECTION'],
|
152 |
|
|
'TEXT_SECTION_BLOCKS' => $TEXT['SECTION_BLOCKS'],
|
153 |
|
|
'TEXT_MANAGE' => $TEXT['MANAGE'],
|
154 |
|
|
'TEXT_SMART_LOGIN' => $TEXT['SMART_LOGIN'],
|
155 |
|
|
'TEXT_PHP_ERROR_LEVEL' => $TEXT['PHP_ERROR_LEVEL'],
|
156 |
|
|
'TEXT_WYSIWYG_STYLE' => $TEXT['WYSIWYG_STYLE'],
|
157 |
|
|
'TEXT_CHARSET' => $TEXT['CHARSET'],
|
158 |
|
|
'TEXT_REDIRECT_AFTER' => $TEXT['REDIRECT_AFTER'],
|
159 |
|
|
'TEXT_SIGNUP' => $TEXT['SIGNUP'].' '.$TEXT['GROUP'],
|
160 |
|
|
'TEXT_MULTILINGUAL' => $TEXT['MULTILINGUAL'],
|
161 |
|
|
'TEXT_HOME_FOLDERS' => $TEXT['HOME_FOLDERS'],
|
162 |
|
|
'TEXT_MANAGE_SECTIONS' => $HEADING['MANAGE_SECTIONS'],
|
163 |
|
|
'TEXT_MULTIPLE_MENUS' => $TEXT['MULTIPLE_MENUS'],
|
164 |
|
|
'TEXT_INLINE' => $TEXT['INLINE'],
|
165 |
|
|
'TEXT_SEPARATE' => $TEXT['SEPARATE'],
|
166 |
|
|
'TEXT_LANGUAGE' => $TEXT['LANGUAGE'],
|
167 |
|
|
'TEXT_TIMEZONE' => $TEXT['TIMEZONE'],
|
168 |
|
|
'TEXT_DATE_FORMAT' => $TEXT['DATE_FORMAT'],
|
169 |
|
|
'TEXT_TIME_FORMAT' => $TEXT['TIME_FORMAT'],
|
170 |
|
|
'TEXT_TEMPLATE' => $TEXT['TEMPLATE'],
|
171 |
|
|
'TEXT_THEME' => $TEXT['THEME'],
|
172 |
|
|
'TEXT_WYSIWYG_EDITOR' => $TEXT['WYSIWYG_EDITOR'],
|
173 |
|
|
'TEXT_PAGE_LEVEL_LIMIT' => $TEXT['PAGE_LEVEL_LIMIT'],
|
174 |
|
|
'TEXT_INTRO_PAGE' => $TEXT['INTRO_PAGE'],
|
175 |
|
|
));
|
176 |
|
|
|
177 |
|
|
// Insert permissions values
|
178 |
|
|
if($admin->get_permission('settings_advanced') != true)
|
179 |
1356
|
Luisehahne
|
{
|
180 |
1777
|
Luisehahne
|
$oTpl->set_var('DISPLAY_ADVANCED_BUTTON', 'hide');
|
181 |
|
|
}
|
182 |
|
|
|
183 |
|
|
/**
|
184 |
|
|
* <!-- BEGIN show_page_level_limit_block -->
|
185 |
|
|
* Insert page level limits
|
186 |
|
|
*/
|
187 |
|
|
$oTpl->set_block('main_block', 'show_page_level_limit_block', 'show_page_level_limit');
|
188 |
|
|
/**
|
189 |
|
|
* <!-- BEGIN page_level_limit_list_block -->
|
190 |
|
|
*/
|
191 |
|
|
$oTpl->set_block('show_page_level_limit_block', 'page_level_limit_list_block', 'page_level_limit_list');
|
192 |
|
|
for($i = 1; $i <= 10; $i++)
|
193 |
|
|
{
|
194 |
|
|
$oTpl->set_var('NUMBER', $i);
|
195 |
|
|
if(PAGE_LEVEL_LIMIT == $i)
|
196 |
|
|
{
|
197 |
|
|
$oTpl->set_var('SELECTED', $sSelected);
|
198 |
|
|
} else {
|
199 |
|
|
$oTpl->set_var('SELECTED', '');
|
200 |
1356
|
Luisehahne
|
}
|
201 |
1777
|
Luisehahne
|
$oTpl->parse('page_level_limit_list', 'page_level_limit_list_block', true);
|
202 |
1356
|
Luisehahne
|
}
|
203 |
|
|
|
204 |
1777
|
Luisehahne
|
/**
|
205 |
|
|
* <!-- END page_level_limit_list_block -->
|
206 |
|
|
* <!-- END show_page_level_limit_block -->
|
207 |
|
|
*/
|
208 |
|
|
if($is_advanced)
|
209 |
|
|
{
|
210 |
|
|
$oTpl->parse('show_page_level_limit', 'show_page_level_limit_block', false);
|
211 |
|
|
} else {
|
212 |
|
|
$oTpl->parse('show_page_level_limit', '');
|
213 |
|
|
}
|
214 |
1716
|
Luisehahne
|
|
215 |
1777
|
Luisehahne
|
/**
|
216 |
|
|
* Work-out if page trash feature is disabled, in-line, or separate
|
217 |
|
|
*/
|
218 |
|
|
if(PAGE_TRASH == 'disabled')
|
219 |
|
|
{
|
220 |
|
|
$oTpl->set_var(array(
|
221 |
|
|
'PAGE_TRASH_DISABLED' => $checked,
|
222 |
|
|
'PAGE_TRASH_INLINE' => '',
|
223 |
|
|
'DISPLAY_PAGE_TRASH_SEPARATE' => 'display: none;',
|
224 |
|
|
));
|
225 |
|
|
} elseif(PAGE_TRASH == 'inline')
|
226 |
|
|
{
|
227 |
|
|
$oTpl->set_var(array(
|
228 |
|
|
'PAGE_TRASH_INLINE' => $checked,
|
229 |
|
|
'PAGE_TRASH_DISABLED' => '',
|
230 |
|
|
'DISPLAY_PAGE_TRASH_SEPARATE' => 'display: none;',
|
231 |
|
|
));
|
232 |
|
|
} elseif(PAGE_TRASH == 'separate')
|
233 |
|
|
{
|
234 |
|
|
$oTpl->set_var('PAGE_TRASH_SEPARATE', $checked);
|
235 |
|
|
$oTpl->set_var('DISPLAY_PAGE_TRASH_SEPARATE', 'display: inline;');
|
236 |
|
|
}
|
237 |
1356
|
Luisehahne
|
|
238 |
1777
|
Luisehahne
|
/**
|
239 |
|
|
* <!-- BEGIN show_checkbox_1_block -->
|
240 |
|
|
* advanced yes
|
241 |
|
|
*/
|
242 |
|
|
$oTpl->set_block('main_block', 'show_checkbox_1_block', 'show_checkbox_1');
|
243 |
|
|
// Work-out if page languages feature is enabled
|
244 |
|
|
if(defined('PAGE_LANGUAGES') && PAGE_LANGUAGES == true)
|
245 |
|
|
{
|
246 |
|
|
$oTpl->set_var(array(
|
247 |
|
|
'PAGE_LANGUAGES_ENABLED' => $checked,
|
248 |
|
|
'PAGE_LANGUAGES_DISABLED' => '',
|
249 |
|
|
));
|
250 |
|
|
} else {
|
251 |
|
|
$oTpl->set_var(array(
|
252 |
|
|
'PAGE_LANGUAGES_DISABLED' => $checked,
|
253 |
|
|
'PAGE_LANGUAGES_ENABLED' => '',
|
254 |
|
|
));
|
255 |
|
|
}
|
256 |
|
|
|
257 |
|
|
// Work-out if page extended feature is enabled
|
258 |
1849
|
Luisehahne
|
if(defined('PAGE_EXTENDET') && PAGE_EXTENDET == true)
|
259 |
1777
|
Luisehahne
|
{
|
260 |
|
|
$oTpl->set_var(array(
|
261 |
1849
|
Luisehahne
|
'PAGE_EXTENDET_ENABLED' => $checked,
|
262 |
|
|
'PAGE_EXTENDET_DISABLED' => '',
|
263 |
1777
|
Luisehahne
|
));
|
264 |
|
|
} else {
|
265 |
|
|
$oTpl->set_var(array(
|
266 |
1849
|
Luisehahne
|
'PAGE_EXTENDET_DISABLED' => $checked,
|
267 |
|
|
'PAGE_EXTENDET_ENABLED' => '',
|
268 |
1777
|
Luisehahne
|
));
|
269 |
|
|
}
|
270 |
|
|
|
271 |
|
|
// Work-out if multiple menus feature is enabled
|
272 |
|
|
if(defined('MULTIPLE_MENUS') && MULTIPLE_MENUS == true)
|
273 |
|
|
{
|
274 |
|
|
$oTpl->set_var(array(
|
275 |
|
|
'MULTIPLE_MENUS_ENABLED' => $checked,
|
276 |
|
|
'MULTIPLE_MENUS_DISABLED' => '',
|
277 |
|
|
));
|
278 |
|
|
} else {
|
279 |
|
|
$oTpl->set_var(array(
|
280 |
|
|
'MULTIPLE_MENUS_DISABLED' => $checked,
|
281 |
|
|
'MULTIPLE_MENUS_ENABLED' => '',
|
282 |
|
|
));
|
283 |
|
|
}
|
284 |
|
|
|
285 |
|
|
/**
|
286 |
|
|
* <!-- END show_checkbox_1_block -->
|
287 |
|
|
* advanced yes
|
288 |
|
|
*/
|
289 |
|
|
if($is_advanced)
|
290 |
|
|
{
|
291 |
|
|
$oTpl->parse('show_checkbox_1', 'show_checkbox_1_block');
|
292 |
|
|
} else {
|
293 |
|
|
$oTpl->parse('show_checkbox_1', '');
|
294 |
|
|
}
|
295 |
|
|
|
296 |
|
|
// Work-out if media home folder feature is enabled
|
297 |
|
|
$oTpl->set_var('TEXT_HOME_FOLDERS', $TEXT['HOME_FOLDERS']);
|
298 |
|
|
if(HOME_FOLDERS)
|
299 |
|
|
{
|
300 |
|
|
$oTpl->set_var(array(
|
301 |
|
|
'HOME_FOLDERS_ENABLED' => $checked,
|
302 |
|
|
'HOME_FOLDERS_DISABLED' => '',
|
303 |
|
|
));
|
304 |
|
|
} else {
|
305 |
|
|
$oTpl->set_var(array(
|
306 |
|
|
'HOME_FOLDERS_DISABLED' => $checked,
|
307 |
|
|
'HOME_FOLDERS_ENABLED' => '',
|
308 |
|
|
));
|
309 |
|
|
}
|
310 |
|
|
|
311 |
|
|
$oTpl->set_block('main_block', 'show_checkbox_2_block', 'show_checkbox_2');
|
312 |
|
|
// Work-out if manage sections feature is enabled
|
313 |
|
|
if(MANAGE_SECTIONS)
|
314 |
|
|
{
|
315 |
|
|
$oTpl->set_var(array(
|
316 |
|
|
'MANAGE_SECTIONS_ENABLED' => $checked,
|
317 |
|
|
'MANAGE_SECTIONS_DISABLED' => '',
|
318 |
|
|
));
|
319 |
|
|
} else {
|
320 |
|
|
$oTpl->set_var(array(
|
321 |
|
|
'MANAGE_SECTIONS_DISABLED' => $checked,
|
322 |
|
|
'MANAGE_SECTIONS_ENABLED' => '',
|
323 |
|
|
));
|
324 |
|
|
}
|
325 |
|
|
|
326 |
|
|
// Work-out if section blocks feature is enabled
|
327 |
|
|
if(defined('SECTION_BLOCKS') && SECTION_BLOCKS == true)
|
328 |
|
|
{
|
329 |
|
|
$oTpl->set_var(array(
|
330 |
|
|
'SECTION_BLOCKS_ENABLED' => $checked,
|
331 |
|
|
'SECTION_BLOCKS_DISABLED' => '',
|
332 |
|
|
));
|
333 |
|
|
} else {
|
334 |
|
|
$oTpl->set_var(array(
|
335 |
|
|
'SECTION_BLOCKS_DISABLED' => $checked,
|
336 |
|
|
'SECTION_BLOCKS_ENABLED' => '',
|
337 |
|
|
));
|
338 |
|
|
}
|
339 |
|
|
|
340 |
|
|
/**
|
341 |
|
|
*
|
342 |
|
|
*/
|
343 |
|
|
if($is_advanced)
|
344 |
|
|
{
|
345 |
|
|
$oTpl->parse('show_checkbox_2', 'show_checkbox_2_block');
|
346 |
|
|
} else {
|
347 |
|
|
$oTpl->parse('show_checkbox_2', '');
|
348 |
|
|
}
|
349 |
|
|
|
350 |
|
|
// Work-out if intro feature is enabled
|
351 |
|
|
if(INTRO_PAGE)
|
352 |
|
|
{
|
353 |
|
|
$oTpl->set_var(array(
|
354 |
|
|
'INTRO_PAGE_ENABLED' => $checked,
|
355 |
|
|
'INTRO_PAGE_DISABLED' => '',
|
356 |
|
|
));
|
357 |
|
|
} else {
|
358 |
|
|
$oTpl->set_var(array(
|
359 |
|
|
'INTRO_PAGE_DISABLED' => $checked,
|
360 |
|
|
'INTRO_PAGE_ENABLED' => '',
|
361 |
|
|
));
|
362 |
|
|
}
|
363 |
|
|
/**
|
364 |
|
|
* <!-- BEGIN show_checkbox_3_block -->
|
365 |
|
|
*/
|
366 |
|
|
$oTpl->set_block('main_block', 'show_checkbox_3_block', 'show_checkbox_3');
|
367 |
|
|
// Work-out if homepage redirection feature is enabled
|
368 |
|
|
if(defined('HOMEPAGE_REDIRECTION') && HOMEPAGE_REDIRECTION == true)
|
369 |
|
|
{
|
370 |
|
|
$oTpl->set_var(array(
|
371 |
|
|
'HOMEPAGE_REDIRECTION_ENABLED' => $checked,
|
372 |
|
|
'HOMEPAGE_REDIRECTION_DISABLED' => '',
|
373 |
|
|
));
|
374 |
|
|
} else {
|
375 |
|
|
// $oTpl->set_var('HOMEPAGE_REDIRECTION_DISABLED', $checked);
|
376 |
|
|
$oTpl->set_var(array(
|
377 |
|
|
'HOMEPAGE_REDIRECTION_DISABLED' => $checked,
|
378 |
|
|
'HOMEPAGE_REDIRECTION_ENABLED' => '',
|
379 |
|
|
));
|
380 |
|
|
}
|
381 |
|
|
// Work-out if smart login feature is enabled
|
382 |
|
|
if(defined('SMART_LOGIN') && SMART_LOGIN == true)
|
383 |
|
|
{
|
384 |
|
|
$oTpl->set_var('SMART_LOGIN_ENABLED', $checked);
|
385 |
|
|
$oTpl->set_var(array(
|
386 |
|
|
'SMART_LOGIN_ENABLED' => $checked,
|
387 |
|
|
'SMART_LOGIN_DISABLED' => '',
|
388 |
|
|
));
|
389 |
|
|
} else {
|
390 |
|
|
$oTpl->set_var('SMART_LOGIN_DISABLED', $checked);
|
391 |
|
|
$oTpl->set_var(array(
|
392 |
|
|
'SMART_LOGIN_DISABLED' => $checked,
|
393 |
|
|
'SMART_LOGIN_ENABLED' => '',
|
394 |
|
|
));
|
395 |
|
|
}
|
396 |
|
|
|
397 |
|
|
/**
|
398 |
|
|
* <!-- END show_checkbox_3_block -->
|
399 |
|
|
*/
|
400 |
|
|
if($is_advanced)
|
401 |
|
|
{
|
402 |
|
|
$oTpl->parse('show_checkbox_3', 'show_checkbox_3_block');
|
403 |
|
|
} else {
|
404 |
|
|
$oTpl->parse('show_checkbox_3', 'show_checkbox_3_block', '');
|
405 |
|
|
}
|
406 |
|
|
|
407 |
|
|
// Work-out if frontend login feature is enabled
|
408 |
|
|
if(FRONTEND_LOGIN)
|
409 |
|
|
{
|
410 |
|
|
$oTpl->set_var(array(
|
411 |
|
|
'PRIVATE_ENABLED' => $checked,
|
412 |
|
|
'PRIVATE_DISABLED' => '',
|
413 |
|
|
));
|
414 |
|
|
} else {
|
415 |
|
|
$oTpl->set_var(array(
|
416 |
|
|
'PRIVATE_DISABLED' => $checked,
|
417 |
1779
|
Luisehahne
|
'PRIVATE_ENABLED' => '',
|
418 |
1777
|
Luisehahne
|
));
|
419 |
|
|
}
|
420 |
|
|
|
421 |
|
|
if(CONFIRMED_REGISTRATION)
|
422 |
|
|
{
|
423 |
|
|
$oTpl->set_var(array(
|
424 |
|
|
'CONFIRMED_REGISTRATION_ENABLED' => $checked,
|
425 |
|
|
'CONFIRMED_REGISTRATION_DISABLED' => '',
|
426 |
|
|
));
|
427 |
|
|
} else {
|
428 |
|
|
$oTpl->set_var(array(
|
429 |
|
|
'CONFIRMED_REGISTRATION_DISABLED' => $checked,
|
430 |
|
|
'CONFIRMED_REGISTRATION_ENABLED' => '',
|
431 |
|
|
));
|
432 |
|
|
}
|
433 |
|
|
|
434 |
|
|
// Insert groups into signup list
|
435 |
|
|
$oTpl->set_block('main_block', 'group_list_block', 'group_list');
|
436 |
|
|
$sql = "SELECT `group_id`, `name` FROM `".TABLE_PREFIX."groups` WHERE `group_id` != '1'";
|
437 |
|
|
if($results = $database->query($sql)) {
|
438 |
|
|
if($results->numRows() > 0)
|
439 |
|
|
{
|
440 |
|
|
while($group = $results->fetchRow(MYSQL_ASSOC))
|
441 |
|
|
{
|
442 |
|
|
$oTpl->set_var('ID', $group['group_id']);
|
443 |
|
|
$oTpl->set_var('NAME', $group['name']);
|
444 |
|
|
if(FRONTEND_SIGNUP == $group['group_id'])
|
445 |
|
|
{
|
446 |
|
|
$oTpl->set_var('SELECTED', $sSelected);
|
447 |
|
|
} else {
|
448 |
|
|
$oTpl->set_var('SELECTED', '');
|
449 |
|
|
}
|
450 |
|
|
$oTpl->parse('group_list', 'group_list_block', true);
|
451 |
|
|
}
|
452 |
|
|
} else {
|
453 |
|
|
$oTpl->set_var('ID', 'disabled');
|
454 |
|
|
$oTpl->set_var('NAME', $MESSAGE['GROUPS']['NO_GROUPS_FOUND']);
|
455 |
|
|
$oTpl->parse('group_list', 'group_list_block', true);
|
456 |
|
|
}
|
457 |
|
|
}
|
458 |
|
|
|
459 |
|
|
/**
|
460 |
|
|
* <!-- BEGIN show_redirect_timer_block -->
|
461 |
|
|
*/
|
462 |
|
|
$oTpl->set_block('main_block', 'show_redirect_timer_block', 'show_redirect_timer');
|
463 |
|
|
|
464 |
|
|
/**
|
465 |
|
|
* <!-- END show_redirect_timer_block -->
|
466 |
|
|
*/
|
467 |
|
|
if($is_advanced)
|
468 |
|
|
{
|
469 |
|
|
$oTpl->parse('show_redirect_timer', 'show_redirect_timer_block');
|
470 |
|
|
} else {
|
471 |
|
|
$oTpl->parse('show_redirect_timer', '');
|
472 |
|
|
}
|
473 |
|
|
|
474 |
|
|
/**
|
475 |
|
|
* <!-- BEGIN show_php_error_level_block -->
|
476 |
|
|
*/
|
477 |
|
|
// Insert default error reporting values
|
478 |
|
|
require(ADMIN_PATH.'/interface/er_levels.php');
|
479 |
|
|
$oTpl->set_block('main_block', 'show_php_error_level_block', 'show_php_error_level');
|
480 |
|
|
$oTpl->set_block('show_php_error_level_block', 'php_error_list_block', 'php_error_list');
|
481 |
|
|
foreach($ER_LEVELS AS $value => $title)
|
482 |
|
|
{
|
483 |
|
|
$oTpl->set_var('VALUE', $value);
|
484 |
|
|
$oTpl->set_var('NAME', $title);
|
485 |
|
|
$selected = (ER_LEVEL == $value) ? $sSelected : '';
|
486 |
|
|
$oTpl->set_var('SELECTED', $selected);
|
487 |
|
|
$oTpl->parse('php_error_list', 'php_error_list_block', true);
|
488 |
|
|
}
|
489 |
|
|
|
490 |
|
|
/**
|
491 |
|
|
* <!-- END show_php_error_level_block -->
|
492 |
|
|
*/
|
493 |
|
|
if($is_advanced)
|
494 |
|
|
{
|
495 |
|
|
$oTpl->parse('show_php_error_level', 'show_php_error_level_block');
|
496 |
|
|
} else {
|
497 |
|
|
$oTpl->parse('show_php_error_level', '');
|
498 |
|
|
}
|
499 |
|
|
|
500 |
|
|
/**
|
501 |
|
|
* <!-- BEGIN show_wysiwyg_block -->
|
502 |
|
|
*/
|
503 |
|
|
// Insert WYSIWYG modules
|
504 |
|
|
$oTpl->set_block('main_block', 'show_wysiwyg_block', 'show_wysiwyg');
|
505 |
|
|
$oTpl->set_block('show_wysiwyg_block', 'editor_list_block', 'editor_list');
|
506 |
|
|
$file='none';
|
507 |
|
|
$module_name=$TEXT['NONE'];
|
508 |
|
|
$oTpl->set_var('FILE', $file);
|
509 |
|
|
$oTpl->set_var('NAME', $module_name);
|
510 |
|
|
$selected = (!defined('WYSIWYG_EDITOR') || $file == WYSIWYG_EDITOR) ? $sSelected : '';
|
511 |
|
|
$oTpl->set_var('SELECTED', $selected);
|
512 |
|
|
$oTpl->parse('editor_list', 'editor_list_block', true);
|
513 |
1716
|
Luisehahne
|
$sql = 'SELECT `name`, `directory` FROM `'.TABLE_PREFIX.'addons` ';
|
514 |
1777
|
Luisehahne
|
$sql .= 'WHERE `type` = \'module\' ';
|
515 |
|
|
$sql .= 'AND `function` = \'wysiwyg\' ';
|
516 |
|
|
$sql .= 'ORDER BY `name`';
|
517 |
|
|
if( ($result = $database->query($sql)) && ($result->numRows() > 0) )
|
518 |
|
|
{
|
519 |
|
|
while($addon = $result->fetchRow(MYSQL_ASSOC))
|
520 |
|
|
{
|
521 |
|
|
if( $admin->get_permission($addon['directory'],'module' ) )
|
522 |
|
|
{
|
523 |
|
|
$oTpl->set_var('FILE', $addon['directory']);
|
524 |
|
|
$oTpl->set_var('NAME', $addon['name']);
|
525 |
|
|
$selected = (!defined('WYSIWYG_EDITOR') || $addon['directory'] == WYSIWYG_EDITOR) ? $sSelected : '';
|
526 |
|
|
$oTpl->set_var('SELECTED', $selected);
|
527 |
|
|
$oTpl->parse('editor_list', 'editor_list_block', true);
|
528 |
|
|
}
|
529 |
|
|
}
|
530 |
|
|
}
|
531 |
|
|
|
532 |
|
|
/**
|
533 |
|
|
* <!-- END show_wysiwyg_block -->
|
534 |
|
|
*/
|
535 |
|
|
if($is_advanced)
|
536 |
|
|
{
|
537 |
|
|
$oTpl->parse('show_wysiwyg','show_wysiwyg_block');
|
538 |
|
|
} else {
|
539 |
|
|
$oTpl->parse('show_wysiwyg', '');
|
540 |
|
|
}
|
541 |
|
|
|
542 |
|
|
// Insert language values
|
543 |
|
|
$oTpl->set_block('main_block', 'language_list_block', 'language_list');
|
544 |
|
|
$sql = 'SELECT `name`, `directory` FROM `'.TABLE_PREFIX.'addons` ';
|
545 |
1716
|
Luisehahne
|
$sql .= 'WHERE `type` = \'language\' ';
|
546 |
|
|
$sql .= 'AND `function` != \'theme\' ';
|
547 |
|
|
$sql .= 'ORDER BY `directory`';
|
548 |
|
|
if( ($result = $database->query($sql)) && ($result->numRows() > 0) )
|
549 |
1356
|
Luisehahne
|
{
|
550 |
1777
|
Luisehahne
|
while($addon = $result->fetchRow(MYSQL_ASSOC)) {
|
551 |
1457
|
Luisehahne
|
$langIcons = (empty($addon['directory'])) ? 'none' : strtolower($addon['directory']);
|
552 |
|
|
|
553 |
1777
|
Luisehahne
|
$oTpl->set_var('CODE', $addon['directory']);
|
554 |
|
|
$oTpl->set_var('NAME', $addon['name']);
|
555 |
|
|
$oTpl->set_var('FLAG', THEME_URL.'/images/flags/'.$langIcons);
|
556 |
|
|
$oTpl->set_var('SELECTED', (DEFAULT_LANGUAGE == $addon['directory'] ? $sSelected : '') );
|
557 |
|
|
$oTpl->parse('language_list', 'language_list_block', true);
|
558 |
1356
|
Luisehahne
|
}
|
559 |
|
|
}
|
560 |
1777
|
Luisehahne
|
/**
|
561 |
|
|
* <!-- BEGIN show_charset_block -->
|
562 |
|
|
*/
|
563 |
|
|
// Insert default charset values
|
564 |
|
|
$oTpl->set_block('main_block', 'show_charset_block', 'show_charset');
|
565 |
|
|
require(ADMIN_PATH.'/interface/charsets.php');
|
566 |
|
|
$oTpl->set_block('show_charset_block', 'charset_list_block', 'charset_list');
|
567 |
|
|
foreach($CHARSETS AS $code => $title) {
|
568 |
|
|
$oTpl->set_var('VALUE', $code);
|
569 |
|
|
$oTpl->set_var('NAME', $title);
|
570 |
|
|
if(DEFAULT_CHARSET == $code) {
|
571 |
|
|
$oTpl->set_var('SELECTED', $sSelected);
|
572 |
|
|
} else {
|
573 |
|
|
$oTpl->set_var('SELECTED', '');
|
574 |
|
|
}
|
575 |
|
|
$oTpl->parse('charset_list', 'charset_list_block', true);
|
576 |
|
|
}
|
577 |
|
|
/**
|
578 |
|
|
* <!-- END show_charset_block -->
|
579 |
|
|
*/
|
580 |
|
|
if($is_advanced)
|
581 |
|
|
{
|
582 |
|
|
$oTpl->parse('show_charset', 'show_charset_block');
|
583 |
|
|
} else {
|
584 |
|
|
$oTpl->parse('show_charset', '');
|
585 |
|
|
}
|
586 |
1356
|
Luisehahne
|
|
587 |
1777
|
Luisehahne
|
// nsert default timezone values
|
588 |
1356
|
Luisehahne
|
require(ADMIN_PATH.'/interface/timezones.php');
|
589 |
1777
|
Luisehahne
|
$oTpl->set_block('main_block', 'timezone_list_block','timezone_list');
|
590 |
1356
|
Luisehahne
|
foreach($TIMEZONES AS $hour_offset => $title)
|
591 |
|
|
{
|
592 |
1777
|
Luisehahne
|
// Make sure we dont list "System Default" as we are setting this value!
|
593 |
1356
|
Luisehahne
|
if($hour_offset != '-20') {
|
594 |
1777
|
Luisehahne
|
$oTpl->set_var('VALUE', $hour_offset);
|
595 |
|
|
$oTpl->set_var('NAME', $title);
|
596 |
1356
|
Luisehahne
|
if(DEFAULT_TIMEZONE == $hour_offset*60*60) {
|
597 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', $sSelected);
|
598 |
1356
|
Luisehahne
|
} else {
|
599 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', '');
|
600 |
1356
|
Luisehahne
|
}
|
601 |
1777
|
Luisehahne
|
$oTpl->parse('timezone_list', 'timezone_list_block', true);
|
602 |
1356
|
Luisehahne
|
}
|
603 |
|
|
}
|
604 |
|
|
|
605 |
1777
|
Luisehahne
|
// Insert date format list
|
606 |
1356
|
Luisehahne
|
require(ADMIN_PATH.'/interface/date_formats.php');
|
607 |
1777
|
Luisehahne
|
$oTpl->set_block('main_block', 'date_format_list_block', 'date_format_list');
|
608 |
1356
|
Luisehahne
|
foreach($DATE_FORMATS AS $format => $title) {
|
609 |
|
|
$format = str_replace('|', ' ', $format); // Add's white-spaces (not able to be stored in array key)
|
610 |
|
|
if($format != 'system_default') {
|
611 |
1777
|
Luisehahne
|
$oTpl->set_var('VALUE', $format);
|
612 |
1356
|
Luisehahne
|
} else {
|
613 |
1777
|
Luisehahne
|
$oTpl->set_var('VALUE', '');
|
614 |
1356
|
Luisehahne
|
}
|
615 |
1777
|
Luisehahne
|
$oTpl->set_var('NAME', $title);
|
616 |
1356
|
Luisehahne
|
if(DEFAULT_DATE_FORMAT == $format) {
|
617 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', $sSelected);
|
618 |
1356
|
Luisehahne
|
} else {
|
619 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', '');
|
620 |
1356
|
Luisehahne
|
}
|
621 |
1777
|
Luisehahne
|
$oTpl->parse('date_format_list', 'date_format_list_block', true);
|
622 |
1356
|
Luisehahne
|
}
|
623 |
|
|
|
624 |
1777
|
Luisehahne
|
// Insert time format list
|
625 |
1356
|
Luisehahne
|
require(ADMIN_PATH.'/interface/time_formats.php');
|
626 |
1777
|
Luisehahne
|
$oTpl->set_block('main_block', 'time_format_list_block', 'time_format_list');
|
627 |
1356
|
Luisehahne
|
foreach($TIME_FORMATS AS $format => $title) {
|
628 |
|
|
$format = str_replace('|', ' ', $format); // Add's white-spaces (not able to be stored in array key)
|
629 |
|
|
if($format != 'system_default') {
|
630 |
1777
|
Luisehahne
|
$oTpl->set_var('VALUE', $format);
|
631 |
1356
|
Luisehahne
|
} else {
|
632 |
1777
|
Luisehahne
|
$oTpl->set_var('VALUE', '');
|
633 |
1356
|
Luisehahne
|
}
|
634 |
1777
|
Luisehahne
|
$oTpl->set_var('NAME', $title);
|
635 |
1356
|
Luisehahne
|
if(DEFAULT_TIME_FORMAT == $format) {
|
636 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', $sSelected);
|
637 |
1356
|
Luisehahne
|
} else {
|
638 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', '');
|
639 |
1356
|
Luisehahne
|
}
|
640 |
1777
|
Luisehahne
|
$oTpl->parse('time_format_list', 'time_format_list_block', true);
|
641 |
1356
|
Luisehahne
|
}
|
642 |
|
|
|
643 |
1716
|
Luisehahne
|
// Insert templates
|
644 |
1777
|
Luisehahne
|
$oTpl->set_block('main_block', 'template_list_block', 'template_list');
|
645 |
1716
|
Luisehahne
|
$sql = 'SELECT `name`, `directory` FROM `'.TABLE_PREFIX.'addons` ';
|
646 |
|
|
$sql .= 'WHERE `type` = \'template\' ';
|
647 |
|
|
$sql .= 'AND `function` != \'theme\' ';
|
648 |
|
|
$sql .= 'ORDER BY `name`';
|
649 |
|
|
if( ($result = $database->query($sql)) && ($result->numRows() > 0) )
|
650 |
|
|
{
|
651 |
1777
|
Luisehahne
|
while($addon = $result->fetchRow(MYSQL_ASSOC))
|
652 |
1716
|
Luisehahne
|
{
|
653 |
|
|
if( $admin->get_permission($addon['directory'],'template' ) )
|
654 |
|
|
{
|
655 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE', $addon['directory']);
|
656 |
|
|
$oTpl->set_var('NAME', $addon['name']);
|
657 |
1716
|
Luisehahne
|
$selected = (($addon['directory'] == DEFAULT_TEMPLATE) ? $sSelected : '');
|
658 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', $selected);
|
659 |
|
|
$oTpl->parse('template_list', 'template_list_block', true);
|
660 |
1716
|
Luisehahne
|
}
|
661 |
1356
|
Luisehahne
|
}
|
662 |
|
|
}
|
663 |
|
|
|
664 |
1716
|
Luisehahne
|
// Insert backend theme
|
665 |
1777
|
Luisehahne
|
$oTpl->set_block('main_block', 'theme_list_block', 'theme_list');
|
666 |
1716
|
Luisehahne
|
$sql = 'SELECT `name`, `directory` FROM `'.TABLE_PREFIX.'addons` ';
|
667 |
|
|
$sql .= 'WHERE `type` = \'template\' ';
|
668 |
|
|
$sql .= 'AND `function` = \'theme\' ';
|
669 |
|
|
$sql .= 'ORDER BY `name`';
|
670 |
|
|
|
671 |
|
|
if( ($result = $database->query($sql)) && ($result->numRows() > 0) )
|
672 |
|
|
{
|
673 |
1777
|
Luisehahne
|
while($addon = $result->fetchRow(MYSQL_ASSOC))
|
674 |
1716
|
Luisehahne
|
{
|
675 |
|
|
if( $admin->get_permission($addon['directory'],'template' ) )
|
676 |
|
|
{
|
677 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE', $addon['directory']);
|
678 |
|
|
$oTpl->set_var('NAME', $addon['name']);
|
679 |
1716
|
Luisehahne
|
$selected = (($addon['directory'] == DEFAULT_THEME) ? $sSelected : '');
|
680 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', $selected);
|
681 |
|
|
$oTpl->parse('theme_list', 'theme_list_block', true);
|
682 |
1716
|
Luisehahne
|
}
|
683 |
1356
|
Luisehahne
|
}
|
684 |
|
|
}
|
685 |
|
|
|
686 |
1777
|
Luisehahne
|
// Work-out if warn_page_leave feature is enabled
|
687 |
|
|
// if (defined('WARN_PAGE_LEAVE') && WARN_PAGE_LEAVE == true)
|
688 |
1716
|
Luisehahne
|
// {
|
689 |
1777
|
Luisehahne
|
// $oTpl->set_var(array(
|
690 |
|
|
// 'WARN_PAGE_LEAVE_ENABLED' => $checked,
|
691 |
|
|
// 'WARN_PAGE_LEAVE_DISABLED' => '',
|
692 |
|
|
// ));
|
693 |
|
|
// } else {
|
694 |
|
|
// $oTpl->set_var(array(
|
695 |
|
|
// 'MANAGE_SECTIONS_DISABLED' => $checked,
|
696 |
|
|
// 'WARN_PAGE_LEAVE_DISABLED' => '',
|
697 |
|
|
// ));
|
698 |
|
|
// }
|
699 |
|
|
|
700 |
|
|
/* Make's sure GD library is installed */
|
701 |
|
|
// if(extension_loaded('gd') && function_exists('imageCreateFromJpeg'))
|
702 |
|
|
// {
|
703 |
|
|
// $oTpl->set_var('GD_EXTENSION_ENABLED', '');
|
704 |
|
|
// } else {
|
705 |
|
|
// $oTpl->set_var('GD_EXTENSION_ENABLED', ' style="display: none;"');
|
706 |
|
|
// }
|
707 |
|
|
|
708 |
|
|
// Insert permissions values
|
709 |
|
|
// if($admin->get_permission('settings_advanced') != true)
|
710 |
|
|
// {
|
711 |
|
|
// $oTpl->set_var('DISPLAY_ADVANCED_BUTTON', 'hide');
|
712 |
|
|
// }
|
713 |
|
|
|
714 |
|
|
/**
|
715 |
|
|
*
|
716 |
|
|
*
|
717 |
|
|
*/
|
718 |
|
|
$oTpl->set_block('main_block', 'show_search_block','show_search');
|
719 |
|
|
$query = "SELECT * FROM `".TABLE_PREFIX."search` WHERE `extra` = '' ";
|
720 |
|
|
if($results = $database->query($query))
|
721 |
|
|
{
|
722 |
|
|
// Query current settings in the db, then loop through them and print them
|
723 |
|
|
while($setting = $results->fetchRow(MYSQL_ASSOC))
|
724 |
|
|
{
|
725 |
|
|
$setting_name = $setting['name'];
|
726 |
|
|
$setting_value = htmlspecialchars(($setting['value']));
|
727 |
|
|
switch($setting_name) {
|
728 |
|
|
// Search header
|
729 |
|
|
case 'header':
|
730 |
|
|
$oTpl->set_var('SEARCH_HEADER', $setting_value);
|
731 |
|
|
break;
|
732 |
|
|
// Search results header
|
733 |
|
|
case 'results_header':
|
734 |
|
|
$oTpl->set_var('SEARCH_RESULTS_HEADER', $setting_value);
|
735 |
|
|
break;
|
736 |
|
|
// Search results loop
|
737 |
|
|
case 'results_loop':
|
738 |
|
|
$oTpl->set_var('SEARCH_RESULTS_LOOP', $setting_value);
|
739 |
|
|
break;
|
740 |
|
|
// Search results footer
|
741 |
|
|
case 'results_footer':
|
742 |
|
|
$oTpl->set_var('SEARCH_RESULTS_FOOTER', $setting_value);
|
743 |
|
|
break;
|
744 |
|
|
// Search no results
|
745 |
|
|
case 'no_results':
|
746 |
|
|
$oTpl->set_var('SEARCH_NO_RESULTS', $setting_value);
|
747 |
|
|
break;
|
748 |
|
|
// Search footer
|
749 |
|
|
case 'footer':
|
750 |
|
|
$oTpl->set_var('SEARCH_FOOTER', $setting_value);
|
751 |
|
|
break;
|
752 |
|
|
// Search module-order
|
753 |
|
|
case 'module_order':
|
754 |
|
|
$oTpl->set_var('SEARCH_MODULE_ORDER', $setting_value);
|
755 |
|
|
break;
|
756 |
|
|
// Search max lines of excerpt
|
757 |
|
|
case 'max_excerpt':
|
758 |
|
|
$oTpl->set_var('SEARCH_MAX_EXCERPT', $setting_value);
|
759 |
|
|
break;
|
760 |
|
|
// time-limit
|
761 |
|
|
case 'time_limit':
|
762 |
|
|
$oTpl->set_var('SEARCH_TIME_LIMIT', $setting_value);
|
763 |
|
|
break;
|
764 |
|
|
// Search template
|
765 |
|
|
case 'template':
|
766 |
|
|
$search_template = $setting_value;
|
767 |
|
|
break;
|
768 |
|
|
}
|
769 |
|
|
}
|
770 |
1356
|
Luisehahne
|
}
|
771 |
|
|
|
772 |
|
|
// Insert templates for search settings
|
773 |
1777
|
Luisehahne
|
$oTpl->set_block('main_block', 'search_template_list_block', 'search_template_list');
|
774 |
1366
|
Luisehahne
|
$search_template = ( ($search_template == DEFAULT_TEMPLATE) || ($search_template == '') ) ? '' : $search_template;
|
775 |
1716
|
Luisehahne
|
$selected = ( ($search_template != DEFAULT_TEMPLATE) ) ? $sSelected : '';
|
776 |
1356
|
Luisehahne
|
|
777 |
1777
|
Luisehahne
|
$oTpl->set_var(array(
|
778 |
1356
|
Luisehahne
|
'FILE' => '',
|
779 |
1777
|
Luisehahne
|
'TEXT_MODULE_ORDER' => $TEXT['MODULE_ORDER'],
|
780 |
1356
|
Luisehahne
|
'NAME' => $TEXT['SYSTEM_DEFAULT'],
|
781 |
|
|
'SELECTED' => $selected
|
782 |
|
|
));
|
783 |
1777
|
Luisehahne
|
$oTpl->parse('search_template_list', 'search_template_list_block', true);
|
784 |
1716
|
Luisehahne
|
$sql = 'SELECT `name`, `directory` FROM `'.TABLE_PREFIX.'addons` ';
|
785 |
|
|
$sql .= 'WHERE `type` = \'template\' ';
|
786 |
|
|
$sql .= 'AND `function` = \'template\' ';
|
787 |
|
|
$sql .= 'ORDER BY `name`';
|
788 |
|
|
if( ($result = $database->query($sql)) && ($result->numRows() > 0) )
|
789 |
1356
|
Luisehahne
|
{
|
790 |
1777
|
Luisehahne
|
while($addon = $result->fetchRow(MYSQL_ASSOC))
|
791 |
1356
|
Luisehahne
|
{
|
792 |
1716
|
Luisehahne
|
if( $admin->get_permission($addon['directory'],'template' ) )
|
793 |
|
|
{
|
794 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE', $addon['directory']);
|
795 |
|
|
$oTpl->set_var('NAME', $addon['name']);
|
796 |
1716
|
Luisehahne
|
$selected = ($addon['directory'] == $search_template) ? $sSelected : '';
|
797 |
1777
|
Luisehahne
|
$oTpl->set_var('SELECTED', $selected);
|
798 |
|
|
$oTpl->parse('search_template_list', 'search_template_list_block', true);
|
799 |
1716
|
Luisehahne
|
}
|
800 |
1356
|
Luisehahne
|
}
|
801 |
|
|
}
|
802 |
|
|
|
803 |
1777
|
Luisehahne
|
// Insert search select
|
804 |
|
|
$oTpl->set_var(array(
|
805 |
|
|
'TEXT_REGISTERED' => $TEXT['REGISTERED'],
|
806 |
|
|
'TEXT_PUBLIC' => $TEXT['PUBLIC'],
|
807 |
|
|
'TEXT_PRIVATE' => $TEXT['PRIVATE'],
|
808 |
|
|
'TEXT_NONE' => $TEXT['NONE'],
|
809 |
|
|
'TEXT_MAX_EXCERPT' => $TEXT['MAX_EXCERPT'],
|
810 |
|
|
'TEXT_TIME_LIMIT' => $TEXT['TIME_LIMIT'],
|
811 |
|
|
'TEXT_VISIBILITY' => $TEXT['VISIBILITY'],
|
812 |
|
|
'TEXT_SEARCH' => $TEXT['SEARCH'],
|
813 |
|
|
));
|
814 |
|
|
if(SEARCH == 'private')
|
815 |
1356
|
Luisehahne
|
{
|
816 |
1777
|
Luisehahne
|
$oTpl->set_var(array(
|
817 |
|
|
'PRIVATE_SEARCH' => $sSelected,
|
818 |
|
|
'REGISTERED_SEARCH' => '',
|
819 |
|
|
'NONE_SEARCH' => '',
|
820 |
1721
|
Luisehahne
|
));
|
821 |
1777
|
Luisehahne
|
} elseif(SEARCH == 'public') {
|
822 |
|
|
$oTpl->set_var(array(
|
823 |
|
|
'PRIVATE_SEARCH' => '',
|
824 |
|
|
'REGISTERED_SEARCH' => '',
|
825 |
|
|
'NONE_SEARCH' => '',
|
826 |
1721
|
Luisehahne
|
));
|
827 |
1777
|
Luisehahne
|
} elseif(SEARCH == 'registered') {
|
828 |
|
|
$oTpl->set_var(array(
|
829 |
|
|
'PRIVATE_SEARCH' => '',
|
830 |
|
|
'REGISTERED_SEARCH' => $sSelected,
|
831 |
|
|
'NONE_SEARCH' => '',
|
832 |
1721
|
Luisehahne
|
));
|
833 |
1777
|
Luisehahne
|
} elseif(SEARCH == 'none') {
|
834 |
|
|
$oTpl->set_var(array(
|
835 |
|
|
'PRIVATE_SEARCH' => '',
|
836 |
|
|
'REGISTERED_SEARCH' => '',
|
837 |
|
|
'NONE_SEARCH' => $sSelected,
|
838 |
1721
|
Luisehahne
|
));
|
839 |
1356
|
Luisehahne
|
}
|
840 |
|
|
|
841 |
1777
|
Luisehahne
|
if($is_advanced)
|
842 |
|
|
{
|
843 |
|
|
$oTpl->parse('show_search', 'show_search_block');
|
844 |
|
|
} else {
|
845 |
|
|
$oTpl->parse('show_search', '');
|
846 |
|
|
}
|
847 |
1409
|
FrankH
|
|
848 |
1777
|
Luisehahne
|
$oTpl->set_block('main_block', 'show_access_block','show_access');
|
849 |
|
|
// Work-out which wbmailer routine should be checked
|
850 |
|
|
$oTpl->set_var(array(
|
851 |
|
|
'TEXT_WBMAILER_DEFAULT_SETTINGS_NOTICE' => $TEXT['WBMAILER_DEFAULT_SETTINGS_NOTICE'],
|
852 |
|
|
'TEXT_WBMAILER_DEFAULT_SENDER_MAIL' => $TEXT['WBMAILER_DEFAULT_SENDER_MAIL'],
|
853 |
|
|
'TEXT_WBMAILER_DEFAULT_SENDER_NAME' => $TEXT['WBMAILER_DEFAULT_SENDER_NAME'],
|
854 |
|
|
'TEXT_WBMAILER_NOTICE' => $TEXT['WBMAILER_NOTICE'],
|
855 |
|
|
'TEXT_WBMAILER_FUNCTION' => $TEXT['WBMAILER_FUNCTION'],
|
856 |
|
|
'TEXT_WBMAILER_SMTP_HOST' => $TEXT['WBMAILER_SMTP_HOST'],
|
857 |
|
|
'TEXT_WBMAILER_PHP' => $TEXT['WBMAILER_PHP'],
|
858 |
|
|
'TEXT_WBMAILER_SMTP' => $TEXT['WBMAILER_SMTP'],
|
859 |
|
|
'TEXT_WBMAILER_SMTP_AUTH' => $TEXT['WBMAILER_SMTP_AUTH'],
|
860 |
|
|
'TEXT_WBMAILER_SMTP_AUTH_NOTICE' => $TEXT['REQUIRED'].' '.$TEXT['WBMAILER_SMTP_AUTH'],
|
861 |
|
|
'TEXT_WBMAILER_SMTP_USERNAME' => $TEXT['WBMAILER_SMTP_USERNAME'],
|
862 |
|
|
'TEXT_WBMAILER_SMTP_PASSWORD' => $TEXT['WBMAILER_SMTP_PASSWORD'],
|
863 |
|
|
'SMTP_AUTH_SELECTED' => $checked
|
864 |
|
|
));
|
865 |
1356
|
Luisehahne
|
|
866 |
1668
|
Luisehahne
|
// Work-out if developer infos feature is enabled
|
867 |
|
|
if(defined('DEV_INFOS') && DEV_INFOS == true)
|
868 |
|
|
{
|
869 |
1777
|
Luisehahne
|
$oTpl->set_var(array(
|
870 |
1721
|
Luisehahne
|
'DEV_INFOS_ENABLED' => $checked,
|
871 |
|
|
'DEV_INFOS_DISABLED' => '',
|
872 |
|
|
));
|
873 |
1668
|
Luisehahne
|
} else {
|
874 |
1777
|
Luisehahne
|
$oTpl->set_var(array(
|
875 |
1721
|
Luisehahne
|
'DEV_INFOS_DISABLED' => $checked,
|
876 |
|
|
'DEV_INFOS_ENABLED' => '',
|
877 |
|
|
));
|
878 |
1668
|
Luisehahne
|
}
|
879 |
|
|
|
880 |
1777
|
Luisehahne
|
// Work-out which server os should be checked
|
881 |
|
|
if(OPERATING_SYSTEM == 'linux')
|
882 |
1731
|
Luisehahne
|
{
|
883 |
1777
|
Luisehahne
|
$oTpl->set_var('LINUX_SELECTED', $checked);
|
884 |
|
|
$oTpl->set_var('WINDOWS_SELECTED', '');
|
885 |
|
|
} elseif(OPERATING_SYSTEM == 'windows') {
|
886 |
|
|
$oTpl->set_var('WINDOWS_SELECTED', $checked);
|
887 |
|
|
$oTpl->set_var('LINUX_SELECTED', '');
|
888 |
1731
|
Luisehahne
|
}
|
889 |
|
|
|
890 |
1356
|
Luisehahne
|
if(WBMAILER_ROUTINE == 'phpmail')
|
891 |
|
|
{
|
892 |
1777
|
Luisehahne
|
$oTpl->set_var('PHPMAIL_SELECTED', $checked);
|
893 |
|
|
$oTpl->set_var('SMTP_VISIBILITY', ' style="display: none;"');
|
894 |
|
|
// $oTpl->set_var('SMTP_VISIBILITY_AUTH', '');
|
895 |
|
|
$oTpl->set_var('SMTP_AUTH_SELECTED', '');
|
896 |
|
|
$oTpl->set_var('SMTPMAIL_SELECTED', '');
|
897 |
1356
|
Luisehahne
|
} elseif(WBMAILER_ROUTINE == 'smtp')
|
898 |
|
|
{
|
899 |
1777
|
Luisehahne
|
$oTpl->set_var('SMTPMAIL_SELECTED', $checked);
|
900 |
|
|
$oTpl->set_var('PHPMAIL_SELECTED', '');
|
901 |
|
|
$oTpl->set_var('SMTP_VISIBILITY', '');
|
902 |
|
|
// $oTpl->set_var('SMTP_VISIBILITY_AUTH', '');
|
903 |
1356
|
Luisehahne
|
}
|
904 |
1572
|
Luisehahne
|
/* deprecated
|
905 |
1356
|
Luisehahne
|
// Work-out if SMTP authentification should be checked
|
906 |
|
|
if(WBMAILER_SMTP_AUTH)
|
907 |
|
|
{
|
908 |
1777
|
Luisehahne
|
$oTpl->set_var('SMTP_AUTH_SELECTED', $checked);
|
909 |
1356
|
Luisehahne
|
if(WBMAILER_ROUTINE == 'smtp')
|
910 |
|
|
{
|
911 |
1777
|
Luisehahne
|
$oTpl->set_var('SMTP_VISIBILITY_AUTH', '');
|
912 |
1356
|
Luisehahne
|
|
913 |
|
|
} else {
|
914 |
1777
|
Luisehahne
|
$oTpl->set_var('SMTP_VISIBILITY_AUTH', ' style="display: none;"');
|
915 |
1356
|
Luisehahne
|
}
|
916 |
|
|
} else {
|
917 |
1777
|
Luisehahne
|
$oTpl->set_var('SMTP_VISIBILITY_AUTH', ' style="display: none;"');
|
918 |
1356
|
Luisehahne
|
}
|
919 |
1572
|
Luisehahne
|
*/
|
920 |
1356
|
Luisehahne
|
|
921 |
1777
|
Luisehahne
|
// Work-out if 777 permissions are set
|
922 |
|
|
$oTpl->set_var('WORLD_WRITEABLE_SELECTED', '');
|
923 |
|
|
if(STRING_FILE_MODE == '0777' AND STRING_DIR_MODE == '0777')
|
924 |
1356
|
Luisehahne
|
{
|
925 |
1777
|
Luisehahne
|
$oTpl->set_var('WORLD_WRITEABLE_SELECTED', $checked);
|
926 |
1356
|
Luisehahne
|
}
|
927 |
|
|
|
928 |
1716
|
Luisehahne
|
|
929 |
1777
|
Luisehahne
|
$oTpl->set_var(array(
|
930 |
|
|
'FILE_U_R_CHECKED' => '',
|
931 |
|
|
'FILE_U_W_CHECKED' => '',
|
932 |
|
|
'FILE_U_E_CHECKED' => '',
|
933 |
|
|
'FILE_G_R_CHECKED' => '',
|
934 |
|
|
'FILE_G_W_CHECKED' => '',
|
935 |
|
|
'FILE_G_E_CHECKED' => '',
|
936 |
|
|
'FILE_O_R_CHECKED' => '',
|
937 |
|
|
'FILE_O_W_CHECKED' => '',
|
938 |
|
|
'FILE_O_E_CHECKED' => '',
|
939 |
|
|
'DIR_U_R_CHECKED' => '',
|
940 |
|
|
'DIR_U_W_CHECKED' => '',
|
941 |
|
|
'DIR_U_E_CHECKED' => '',
|
942 |
|
|
'DIR_G_R_CHECKED' => '',
|
943 |
|
|
'DIR_G_W_CHECKED' => '',
|
944 |
|
|
'DIR_G_E_CHECKED' => '',
|
945 |
|
|
'DIR_O_R_CHECKED' => '',
|
946 |
|
|
'DIR_O_W_CHECKED' => '',
|
947 |
|
|
'DIR_O_E_CHECKED' => '',
|
948 |
|
|
));
|
949 |
1356
|
Luisehahne
|
|
950 |
1777
|
Luisehahne
|
// Work-out which file mode boxes are checked
|
951 |
1356
|
Luisehahne
|
if(extract_permission(STRING_FILE_MODE, 'u', 'r'))
|
952 |
|
|
{
|
953 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_U_R_CHECKED', $checked);
|
954 |
1356
|
Luisehahne
|
}
|
955 |
|
|
if(extract_permission(STRING_FILE_MODE, 'u', 'w'))
|
956 |
|
|
{
|
957 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_U_W_CHECKED', $checked);
|
958 |
1356
|
Luisehahne
|
}
|
959 |
|
|
if(extract_permission(STRING_FILE_MODE, 'u', 'e'))
|
960 |
|
|
{
|
961 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_U_E_CHECKED', $checked);
|
962 |
1356
|
Luisehahne
|
}
|
963 |
|
|
if(extract_permission(STRING_FILE_MODE, 'g', 'r'))
|
964 |
|
|
{
|
965 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_G_R_CHECKED', $checked);
|
966 |
1356
|
Luisehahne
|
}
|
967 |
|
|
if(extract_permission(STRING_FILE_MODE, 'g', 'w'))
|
968 |
|
|
{
|
969 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_G_W_CHECKED', $checked);
|
970 |
1356
|
Luisehahne
|
}
|
971 |
|
|
if(extract_permission(STRING_FILE_MODE, 'g', 'e'))
|
972 |
|
|
{
|
973 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_G_E_CHECKED', $checked);
|
974 |
1356
|
Luisehahne
|
}
|
975 |
|
|
if(extract_permission(STRING_FILE_MODE, 'o', 'r'))
|
976 |
|
|
{
|
977 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_O_R_CHECKED', $checked);
|
978 |
1356
|
Luisehahne
|
}
|
979 |
|
|
if(extract_permission(STRING_FILE_MODE, 'o', 'w'))
|
980 |
|
|
{
|
981 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_O_W_CHECKED', $checked);
|
982 |
1356
|
Luisehahne
|
}
|
983 |
|
|
if(extract_permission(STRING_FILE_MODE, 'o', 'e'))
|
984 |
|
|
{
|
985 |
1777
|
Luisehahne
|
$oTpl->set_var('FILE_O_E_CHECKED', $checked);
|
986 |
1356
|
Luisehahne
|
}
|
987 |
|
|
// Work-out which dir mode boxes are checked
|
988 |
|
|
if(extract_permission(STRING_DIR_MODE, 'u', 'r'))
|
989 |
|
|
{
|
990 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_U_R_CHECKED', $checked);
|
991 |
1356
|
Luisehahne
|
}
|
992 |
|
|
if(extract_permission(STRING_DIR_MODE, 'u', 'w'))
|
993 |
|
|
{
|
994 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_U_W_CHECKED', $checked);
|
995 |
1356
|
Luisehahne
|
}
|
996 |
|
|
if(extract_permission(STRING_DIR_MODE, 'u', 'e'))
|
997 |
|
|
{
|
998 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_U_E_CHECKED', $checked);
|
999 |
1356
|
Luisehahne
|
}
|
1000 |
|
|
if(extract_permission(STRING_DIR_MODE, 'g', 'r'))
|
1001 |
|
|
{
|
1002 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_G_R_CHECKED', $checked);
|
1003 |
1356
|
Luisehahne
|
}
|
1004 |
|
|
if(extract_permission(STRING_DIR_MODE, 'g', 'w'))
|
1005 |
|
|
{
|
1006 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_G_W_CHECKED', $checked);
|
1007 |
1356
|
Luisehahne
|
}
|
1008 |
|
|
if(extract_permission(STRING_DIR_MODE, 'g', 'e'))
|
1009 |
|
|
{
|
1010 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_G_E_CHECKED', $checked);
|
1011 |
1356
|
Luisehahne
|
}
|
1012 |
|
|
if(extract_permission(STRING_DIR_MODE, 'o', 'r'))
|
1013 |
|
|
{
|
1014 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_O_R_CHECKED', $checked);
|
1015 |
1356
|
Luisehahne
|
}
|
1016 |
|
|
if(extract_permission(STRING_DIR_MODE, 'o', 'w'))
|
1017 |
|
|
{
|
1018 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_O_W_CHECKED', $checked);
|
1019 |
1356
|
Luisehahne
|
}
|
1020 |
|
|
if(extract_permission(STRING_DIR_MODE, 'o', 'e'))
|
1021 |
|
|
{
|
1022 |
1777
|
Luisehahne
|
$oTpl->set_var('DIR_O_E_CHECKED', $checked);
|
1023 |
1356
|
Luisehahne
|
}
|
1024 |
1843
|
Luisehahne
|
$sReadOnly = '';
|
1025 |
|
|
$sPagesEditType = 'text';
|
1026 |
|
|
if( $bPagesCanModify = ($database->get_one('SELECT COUNT(*) FROM `'.TABLE_PREFIX.'pages`'))!=0 ) {
|
1027 |
|
|
$sReadOnly = ' readonly="readonly"';
|
1028 |
1844
|
Luisehahne
|
$sPagesEditType = 'grey bold';
|
1029 |
1843
|
Luisehahne
|
}
|
1030 |
1356
|
Luisehahne
|
|
1031 |
1777
|
Luisehahne
|
$oTpl->set_var(array(
|
1032 |
|
|
'PAGES_DIRECTORY' => PAGES_DIRECTORY,
|
1033 |
1843
|
Luisehahne
|
'PAGES_READONLY' => $sReadOnly,
|
1034 |
|
|
'PAGES_EDIT_TYPE' => $sPagesEditType,
|
1035 |
1777
|
Luisehahne
|
'MODULES_DIRECTORY' => MODULES_UPGRADE_LIST,
|
1036 |
|
|
'PAGE_ICON_DIR' => PAGE_ICON_DIR,
|
1037 |
|
|
'MEDIA_DIRECTORY' => MEDIA_DIRECTORY,
|
1038 |
|
|
'PAGE_EXTENSION' => PAGE_EXTENSION,
|
1039 |
|
|
'PAGE_SPACER' => PAGE_SPACER,
|
1040 |
|
|
'TABLE_PREFIX' => TABLE_PREFIX
|
1041 |
|
|
));
|
1042 |
1356
|
Luisehahne
|
|
1043 |
|
|
// Insert Server Email value into template
|
1044 |
1777
|
Luisehahne
|
$oTpl->set_var('SERVER_EMAIL', SERVER_EMAIL);
|
1045 |
1356
|
Luisehahne
|
|
1046 |
1777
|
Luisehahne
|
// Insert language text and messages
|
1047 |
|
|
$oTpl->set_var(array(
|
1048 |
|
|
'TEXT_DEV_INFOS' => $TEXT['DEV_INFOS'],
|
1049 |
|
|
'TEXT_PAGES_DIRECTORY' => $TEXT['PAGES_DIRECTORY'],
|
1050 |
|
|
'TEXT_PAGE_ICON_DIR' => $TEXT['PAGE_ICON_DIR'],
|
1051 |
|
|
'TEXT_MEDIA_DIRECTORY' => $TEXT['MEDIA_DIRECTORY'],
|
1052 |
|
|
'TEXT_PAGE_EXTENSION' => $TEXT['PAGE_EXTENSION'],
|
1053 |
|
|
'TEXT_PAGE_SPACER' => $TEXT['PAGE_SPACER'],
|
1054 |
|
|
'TEXT_RENAME_FILES_ON_UPLOAD' => $TEXT['RENAME_FILES_ON_UPLOAD'],
|
1055 |
|
|
'TEXT_APP_NAME' => $TEXT['APP_NAME'],
|
1056 |
|
|
'TEXT_SESSION_IDENTIFIER' => $TEXT['SESSION_IDENTIFIER'],
|
1057 |
|
|
'TEXT_SEC_ANCHOR' => $TEXT['SEC_ANCHOR'],
|
1058 |
|
|
'TEXT_SERVER_OPERATING_SYSTEM' => $TEXT['SERVER_OPERATING_SYSTEM'],
|
1059 |
|
|
'TEXT_LINUX_UNIX_BASED' => $TEXT['LINUX_UNIX_BASED'],
|
1060 |
|
|
'TEXT_WINDOWS' => $TEXT['WINDOWS'],
|
1061 |
|
|
'TEXT_ADMIN' => $TEXT['ADMIN'],
|
1062 |
|
|
'TEXT_TYPE' => $TEXT['TYPE'],
|
1063 |
|
|
'TEXT_DATABASE' => $TEXT['DATABASE'],
|
1064 |
|
|
'TEXT_HOST' => $TEXT['HOST'],
|
1065 |
|
|
'TEXT_USERNAME' => $TEXT['USERNAME'],
|
1066 |
|
|
'TEXT_PASSWORD' => $TEXT['PASSWORD'],
|
1067 |
|
|
'TEXT_NAME' => $TEXT['NAME'],
|
1068 |
|
|
'TEXT_TABLE_PREFIX' => $TEXT['TABLE_PREFIX'],
|
1069 |
|
|
'TEXT_CHANGES' => $TEXT['CHANGES'],
|
1070 |
|
|
'TEXT_FILES' => strtoupper(substr($TEXT['FILES'], 0, 1)).substr($TEXT['FILES'], 1),
|
1071 |
|
|
'TEXT_DIRECTORIES' => $TEXT['DIRECTORIES'],
|
1072 |
|
|
'TEXT_FILESYSTEM_PERMISSIONS' => $TEXT['FILESYSTEM_PERMISSIONS'],
|
1073 |
|
|
'TEXT_USER' => $TEXT['USER'],
|
1074 |
|
|
'TEXT_GROUP' => $TEXT['GROUP'],
|
1075 |
|
|
'TEXT_OTHERS' => $TEXT['OTHERS'],
|
1076 |
|
|
'TEXT_READ' => $TEXT['READ'],
|
1077 |
|
|
'TEXT_WRITE' => $TEXT['WRITE'],
|
1078 |
|
|
'TEXT_EXECUTE' => $TEXT['EXECUTE'],
|
1079 |
|
|
'TEXT_WARN_PAGE_LEAVE' => '',
|
1080 |
|
|
'TEXT_WORLD_WRITEABLE_FILE_PERMISSIONS' => $TEXT['WORLD_WRITEABLE_FILE_PERMISSIONS'],
|
1081 |
|
|
'MODE_SWITCH_WARNING' => $MESSAGE['SETTINGS_MODE_SWITCH_WARNING'],
|
1082 |
|
|
'WORLD_WRITEABLE_WARNING' => $MESSAGE['SETTINGS_WORLD_WRITEABLE_WARNING'],
|
1083 |
|
|
));
|
1084 |
1356
|
Luisehahne
|
|
1085 |
1572
|
Luisehahne
|
if($is_advanced && $admin->get_user_id()=='1')
|
1086 |
|
|
{
|
1087 |
1777
|
Luisehahne
|
$oTpl->parse('show_access', 'show_access_block');
|
1088 |
1572
|
Luisehahne
|
}else {
|
1089 |
1777
|
Luisehahne
|
$oTpl->parse('show_access' , '');
|
1090 |
1572
|
Luisehahne
|
}
|
1091 |
1356
|
Luisehahne
|
|
1092 |
|
|
// Parse template objects output
|
1093 |
1777
|
Luisehahne
|
$oTpl->parse('main', 'main_block',false);
|
1094 |
|
|
$oTpl->pparse('output', 'page');
|
1095 |
|
|
//$oTpl->p('page');
|
1096 |
|
|
unset($oTpl);
|
1097 |
1356
|
Luisehahne
|
$admin->print_footer();
|