@@ -21,8 +21,8 @@ |
||
21 | 21 | $userid = $userid + 0; |
22 | 22 | |
23 | 23 | // data changed - delete statpic of user, if exists - will be recreated on next request |
24 | - if (file_exists('./images/statpics/statpic' . $userid . '.jpg')) { |
|
25 | - unlink('./images/statpics/statpic' . $userid . '.jpg'); |
|
24 | + if (file_exists('./images/statpics/statpic'.$userid.'.jpg')) { |
|
25 | + unlink('./images/statpics/statpic'.$userid.'.jpg'); |
|
26 | 26 | } |
27 | 27 | } |
28 | 28 |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | $style = 'ocstyle'; |
32 | 32 | |
33 | 33 | // include common settings of lib1 and lib2 |
34 | -require_once $rootpath . 'config2/settings-dist-common.inc.php'; |
|
34 | +require_once $rootpath.'config2/settings-dist-common.inc.php'; |
|
35 | 35 | |
36 | 36 | //id of the node; see list in config2/settings-dist.inc.php |
37 | 37 | $oc_nodeid = 0; |
@@ -126,7 +126,7 @@ discard block |
||
126 | 126 | |
127 | 127 | // sql debugging |
128 | 128 | $sql_allow_debug = 0; |
129 | -$sql_debug_cryptkey = 'this is my very, very secret \'secret key\''; // min. 24 chars |
|
129 | +$sql_debug_cryptkey = 'this is my very, very secret \'secret key\''; // min. 24 chars |
|
130 | 130 | |
131 | 131 | // replacements for sql() |
132 | 132 | $sql_replacements['db'] = $dbname; |
@@ -148,10 +148,10 @@ discard block |
||
148 | 148 | |
149 | 149 | /* default locale |
150 | 150 | */ |
151 | -$opt['template']['default']['locale'] = 'DE'; // can be overwritten by $opt['domain'][<domain>]['locale'] |
|
151 | +$opt['template']['default']['locale'] = 'DE'; // can be overwritten by $opt['domain'][<domain>]['locale'] |
|
152 | 152 | |
153 | 153 | // include all locale settings |
154 | -require_once $rootpath . 'config2/locale.inc.php'; |
|
154 | +require_once $rootpath.'config2/locale.inc.php'; |
|
155 | 155 | |
156 | 156 | /* replicated slave databases |
157 | 157 | * use same config as in config2/settings.inc.php (!) |
@@ -198,7 +198,7 @@ discard block |
||
198 | 198 | 'menustring' => t('Geokrety'), |
199 | 199 | 'siteid' => 'geokrety', |
200 | 200 | 'visible' => true, |
201 | - 'filename' => 'http://geokrety.org/index.php?lang=' . (isset($locale) ? strtolower($locale) : 'de') |
|
201 | + 'filename' => 'http://geokrety.org/index.php?lang='.(isset($locale) ? strtolower($locale) : 'de') |
|
202 | 202 | ]; |
203 | 203 | |
204 | 204 | $menu[] = [ |
@@ -9,7 +9,7 @@ discard block |
||
9 | 9 | * Unicode Reminder メモ |
10 | 10 | ****************************************************************************/ |
11 | 11 | |
12 | -require_once $opt['rootpath'] . 'lib/bench.inc.php'; |
|
12 | +require_once $opt['rootpath'].'lib/bench.inc.php'; |
|
13 | 13 | |
14 | 14 | $sqldbg_cmdNo = 0; |
15 | 15 | $sqldbg_sumTimes = 0; |
@@ -155,9 +155,9 @@ discard block |
||
155 | 155 | global $sqldbg_cmdNo; |
156 | 156 | global $sqldbg_sumTimes; |
157 | 157 | |
158 | - $sqldbg_cmdNo ++; |
|
158 | + $sqldbg_cmdNo++; |
|
159 | 159 | |
160 | - echo '<p class="sqlno"><span class="white">/*</span> SQL command ' . $sqldbg_cmdNo . ' '; |
|
160 | + echo '<p class="sqlno"><span class="white">/*</span> SQL command '.$sqldbg_cmdNo.' '; |
|
161 | 161 | if ($bSlave) { |
162 | 162 | echo '<span class="slave_title">(slave)</span>'; |
163 | 163 | } |
@@ -224,19 +224,19 @@ discard block |
||
224 | 224 | $bFirstLine = true; |
225 | 225 | $nLine = 0; |
226 | 226 | $rs = mysql_query($sqlexplain, $dblink); |
227 | - echo '<div class="selrows">Number of selected rows: ' . mysql_num_rows($rs) . '</div>'; |
|
227 | + echo '<div class="selrows">Number of selected rows: '.mysql_num_rows($rs).'</div>'; |
|
228 | 228 | |
229 | 229 | echo '<table class="firstresultrow" border="1">'; |
230 | 230 | |
231 | 231 | while ($r = sql_fetch_assoc($rs)) { |
232 | 232 | $usebr = true; |
233 | - $nLine ++; |
|
233 | + $nLine++; |
|
234 | 234 | if ($bFirstLine == true) { |
235 | - echo '<tr>' . "\n"; |
|
235 | + echo '<tr>'."\n"; |
|
236 | 236 | foreach ($r as $field => $value) { |
237 | - echo '<th>' . htmlspecialchars($field, ENT_COMPAT, 'UTF-8') . '</th>' . "\n"; |
|
237 | + echo '<th>'.htmlspecialchars($field, ENT_COMPAT, 'UTF-8').'</th>'."\n"; |
|
238 | 238 | } |
239 | - echo '</tr>' . "\n"; |
|
239 | + echo '</tr>'."\n"; |
|
240 | 240 | } |
241 | 241 | |
242 | 242 | if ($bFirstLine) { |
@@ -246,9 +246,9 @@ discard block |
||
246 | 246 | } |
247 | 247 | |
248 | 248 | foreach ($r as $value) { |
249 | - echo '<td>' . htmlspecialchars(($value != null) ? $value : 'NULL', ENT_COMPAT, 'UTF-8') . '</td>'; |
|
249 | + echo '<td>'.htmlspecialchars(($value != null) ? $value : 'NULL', ENT_COMPAT, 'UTF-8').'</td>'; |
|
250 | 250 | } |
251 | - echo '</tr>' . "\n"; |
|
251 | + echo '</tr>'."\n"; |
|
252 | 252 | |
253 | 253 | if ($nLine == 25) { |
254 | 254 | break; |
@@ -261,27 +261,27 @@ discard block |
||
261 | 261 | echo '<table class="explain" border="1">'; |
262 | 262 | |
263 | 263 | $bFirstLine = true; |
264 | - $rs = mysql_query('EXPLAIN EXTENDED ' . $sqlexplain); |
|
264 | + $rs = mysql_query('EXPLAIN EXTENDED '.$sqlexplain); |
|
265 | 265 | while ($r = sql_fetch_assoc($rs)) { |
266 | 266 | if ($bFirstLine == true) { |
267 | 267 | echo '<tr>'; |
268 | 268 | foreach ($r as $field => $value) { |
269 | - echo '<th>' . htmlspecialchars($field, ENT_COMPAT, 'UTF-8') . '</th>'; |
|
269 | + echo '<th>'.htmlspecialchars($field, ENT_COMPAT, 'UTF-8').'</th>'; |
|
270 | 270 | } |
271 | - echo '</tr>' . "\n"; |
|
271 | + echo '</tr>'."\n"; |
|
272 | 272 | |
273 | 273 | $bFirstLine = false; |
274 | 274 | } |
275 | 275 | |
276 | 276 | echo '<tr>'; |
277 | 277 | foreach ($r as $value) { |
278 | - echo '<td>' . htmlspecialchars( |
|
278 | + echo '<td>'.htmlspecialchars( |
|
279 | 279 | ($value != null) ? mb_ereg_replace('\*/', '* /', $value) : 'NULL', |
280 | 280 | ENT_COMPAT, |
281 | 281 | 'UTF-8' |
282 | - ) . '</td>'; |
|
282 | + ).'</td>'; |
|
283 | 283 | } |
284 | - echo '</tr>' . "\n"; |
|
284 | + echo '</tr>'."\n"; |
|
285 | 285 | } |
286 | 286 | echo '</table>'; |
287 | 287 | $usebr = true; |
@@ -303,14 +303,14 @@ discard block |
||
303 | 303 | echo '<table>'; |
304 | 304 | $rs = mysql_query('SHOW WARNINGS', $dblink); |
305 | 305 | while ($r = sql_fetch_assoc($rs)) { |
306 | - echo '<tr><td>' . htmlspecialchars($r['Message'], ENT_COMPAT, 'UTF-8') . '</td></tr>'; |
|
306 | + echo '<tr><td>'.htmlspecialchars($r['Message'], ENT_COMPAT, 'UTF-8').'</td></tr>'; |
|
307 | 307 | } |
308 | 308 | echo '</table>'; |
309 | 309 | echo '</div>'; |
310 | 310 | } |
311 | 311 | |
312 | - echo '<div class="runtime">Runtime: ' . sprintf('%01.5f', $bSqlExecution->Diff()) . ' sek.</div>'; |
|
313 | - echo '<div class="affectedrows">Number of affected rows: ' . mysql_affected_rows($dblink) . '</div>'; |
|
312 | + echo '<div class="runtime">Runtime: '.sprintf('%01.5f', $bSqlExecution->Diff()).' sek.</div>'; |
|
313 | + echo '<div class="affectedrows">Number of affected rows: '.mysql_affected_rows($dblink).'</div>'; |
|
314 | 314 | |
315 | 315 | echo '<div class="white">*/</div></div>'; |
316 | 316 | |
@@ -322,7 +322,7 @@ discard block |
||
322 | 322 | global $sqldbg_sumTimes; |
323 | 323 | |
324 | 324 | echo '<span class="white">/*</span><div class="allruntime"><hr>'; |
325 | - echo 'Runtime sum: ' . sprintf('%01.5f', $sqldbg_sumTimes) . ' sek.<span class="white">*/</span></div>'; |
|
325 | + echo 'Runtime sum: '.sprintf('%01.5f', $sqldbg_sumTimes).' sek.<span class="white">*/</span></div>'; |
|
326 | 326 | |
327 | 327 | echo '</body></html>'; |
328 | 328 | exit; |
@@ -347,13 +347,13 @@ discard block |
||
347 | 347 | return ''; |
348 | 348 | } |
349 | 349 | |
350 | - return 'SELECT * ' . mb_substr($sql, $start); |
|
350 | + return 'SELECT * '.mb_substr($sql, $start); |
|
351 | 351 | } |
352 | 352 | |
353 | 353 | function sqldbg_insert_nocache($sql) |
354 | 354 | { |
355 | 355 | if (mb_strtoupper(mb_substr($sql, 0, 7)) == 'SELECT ') { |
356 | - $sql = 'SELECT SQL_NO_CACHE ' . mb_substr($sql, 7); |
|
356 | + $sql = 'SELECT SQL_NO_CACHE '.mb_substr($sql, 7); |
|
357 | 357 | } |
358 | 358 | |
359 | 359 | return $sql; |
@@ -16,7 +16,7 @@ discard block |
||
16 | 16 | * Dont include this file by hand - it will be included from common.inc.php |
17 | 17 | ****************************************************************************/ |
18 | 18 | |
19 | -require $opt['rootpath'] . 'lib/login.class.php'; |
|
19 | +require $opt['rootpath'].'lib/login.class.php'; |
|
20 | 20 | |
21 | 21 | $autherr = 0; |
22 | 22 | define('AUTHERR_NOERROR', 0); |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | if ($login->userid != 0) { |
37 | 37 | //set up $usr array |
38 | 38 | $usr['userid'] = $login->userid; |
39 | - $usr['email'] = sqlValue("SELECT `email` FROM `user` WHERE `user_id`='" . sql_escape($login->userid) . "'", ''); |
|
39 | + $usr['email'] = sqlValue("SELECT `email` FROM `user` WHERE `user_id`='".sql_escape($login->userid)."'", ''); |
|
40 | 40 | $usr['username'] = $login->username; |
41 | 41 | $usr['admin'] = $login->admin; |
42 | 42 | } else { |
@@ -19,7 +19,7 @@ discard block |
||
19 | 19 | |
20 | 20 | //relative path to the root directory |
21 | 21 | if (!isset($rootpath)) { |
22 | - $rootpath = dirname(__FILE__) . '/../'; |
|
22 | + $rootpath = dirname(__FILE__).'/../'; |
|
23 | 23 | } |
24 | 24 | |
25 | 25 | //default used language |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | $style = 'ocstyle'; |
37 | 37 | |
38 | 38 | // include common settings of lib1 and lib2 |
39 | -require_once $rootpath . 'config2/settings-dist-common.inc.php'; |
|
39 | +require_once $rootpath.'config2/settings-dist-common.inc.php'; |
|
40 | 40 | |
41 | 41 | //id of the node; see config2/settings-dist.inc.php |
42 | 42 | $oc_nodeid = 4; |
@@ -74,10 +74,10 @@ discard block |
||
74 | 74 | $maildomain = 'local.opencaching.de'; |
75 | 75 | } |
76 | 76 | if (!isset($emailaddr)) { |
77 | - $emailaddr = 'root@' . $maildomain; |
|
77 | + $emailaddr = 'root@'.$maildomain; |
|
78 | 78 | } |
79 | 79 | if (!isset($opt['mail']['contact'])) { |
80 | - $opt['mail']['contact'] = 'contact@' . $maildomain; |
|
80 | + $opt['mail']['contact'] = 'contact@'.$maildomain; |
|
81 | 81 | } |
82 | 82 | |
83 | 83 | // news settings |
@@ -106,7 +106,7 @@ discard block |
||
106 | 106 | |
107 | 107 | // safemode_zip-binary |
108 | 108 | $safemode_zip = '/var/www/bin/phpzip.php'; |
109 | -$zip_basedir = $dev_basepath . ($dev_codepath == '*' ? '' : $dev_codepath . 'htdocs/') . 'download/zip/'; |
|
109 | +$zip_basedir = $dev_basepath.($dev_codepath == '*' ? '' : $dev_codepath.'htdocs/').'download/zip/'; |
|
110 | 110 | $zip_wwwdir = 'download/zip/'; |
111 | 111 | |
112 | 112 | $googlemap_key = "<key>"; |
@@ -117,17 +117,17 @@ discard block |
||
117 | 117 | /* maximum number of failed logins per hour before that IP address is blocked |
118 | 118 | * (used to prevent brute-force-attacks) |
119 | 119 | */ |
120 | -$opt['page']['max_logins_per_hour'] = 1000; // for development ... |
|
120 | +$opt['page']['max_logins_per_hour'] = 1000; // for development ... |
|
121 | 121 | $opt['page']['headoverlay'] = 'oc_head_alpha3'; |
122 | 122 | |
123 | 123 | // data license |
124 | -$opt['logic']['license']['disclaimer'] = true; // also in lib2/settings-dist.inc.php |
|
125 | -$opt['logic']['license']['terms'] = $absolute_server_URI . 'articles.php?page=impressum#datalicense'; |
|
124 | +$opt['logic']['license']['disclaimer'] = true; // also in lib2/settings-dist.inc.php |
|
125 | +$opt['logic']['license']['terms'] = $absolute_server_URI.'articles.php?page=impressum#datalicense'; |
|
126 | 126 | |
127 | 127 | $opt['logic']['admin']['listingadmin_notification'] = 'root'; |
128 | 128 | |
129 | 129 | // include all locale settings |
130 | -require_once $rootpath . 'config2/locale.inc.php'; |
|
130 | +require_once $rootpath.'config2/locale.inc.php'; |
|
131 | 131 | |
132 | 132 | /* replicated slave databases |
133 | 133 | * use same config as in config2/settings.inc.php (!) |
@@ -18,7 +18,7 @@ |
||
18 | 18 | |
19 | 19 | // database names |
20 | 20 | $dbname = 'opencaching'; |
21 | -$tmpdbname = 'octmp'; // empty db with CREATE and DROP privileges |
|
21 | +$tmpdbname = 'octmp'; // empty db with CREATE and DROP privileges |
|
22 | 22 | |
23 | 23 | // common developer system settings |
24 | 24 | require 'settings-dev.inc.php'; |
@@ -15,8 +15,8 @@ discard block |
||
15 | 15 | return sqlValue( |
16 | 16 | "SELECT IFNULL(`stt`.`text`, `cache_type`.`en`) |
17 | 17 | FROM `cache_type` |
18 | - LEFT JOIN `sys_trans_text` `stt` ON `stt`.`trans_id`=`cache_type`.`trans_id` AND `stt`.`lang`='" . sql_escape($language) . "' |
|
19 | - WHERE `cache_type`.`id`='" . sql_escape($cachetype) . "'", |
|
18 | + LEFT JOIN `sys_trans_text` `stt` ON `stt`.`trans_id`=`cache_type`.`trans_id` AND `stt`.`lang`='" . sql_escape($language)."' |
|
19 | + WHERE `cache_type`.`id`='" . sql_escape($cachetype)."'", |
|
20 | 20 | '' |
21 | 21 | ); |
22 | 22 | } |
@@ -26,8 +26,8 @@ discard block |
||
26 | 26 | return sqlValue( |
27 | 27 | "SELECT IFNULL(`stt`.`text`, `cache_size`.`en`) |
28 | 28 | FROM `cache_size` |
29 | - LEFT JOIN `sys_trans_text` `stt` ON `stt`.`trans_id`=`cache_size`.`trans_id` AND `stt`.`lang`='" . sql_escape($language) . "' |
|
30 | - WHERE `cache_size`.`id`='" . sql_escape($cachesize) . "'", |
|
29 | + LEFT JOIN `sys_trans_text` `stt` ON `stt`.`trans_id`=`cache_size`.`trans_id` AND `stt`.`lang`='" . sql_escape($language)."' |
|
30 | + WHERE `cache_size`.`id`='" . sql_escape($cachesize)."'", |
|
31 | 31 | '' |
32 | 32 | ); |
33 | 33 | } |
@@ -37,8 +37,8 @@ discard block |
||
37 | 37 | return sqlValue( |
38 | 38 | "SELECT IFNULL(`stt`.`text`, `log_types`.`en`) |
39 | 39 | FROM `log_types` |
40 | - LEFT JOIN `sys_trans_text` `stt` ON `stt`.`trans_id`=`log_types`.`trans_id` AND `stt`.`lang`='" . sql_escape($language) . "' |
|
41 | - WHERE `log_types`.`id`='" . sql_escape($logtype) . "'", |
|
40 | + LEFT JOIN `sys_trans_text` `stt` ON `stt`.`trans_id`=`log_types`.`trans_id` AND `stt`.`lang`='" . sql_escape($language)."' |
|
41 | + WHERE `log_types`.`id`='" . sql_escape($logtype)."'", |
|
42 | 42 | '' |
43 | 43 | ); |
44 | 44 | } |
@@ -9,10 +9,10 @@ discard block |
||
9 | 9 | * Unicode Reminder メモ |
10 | 10 | ***************************************************************************/ |
11 | 11 | |
12 | -require_once __DIR__ . '/lib/consts.inc.php'; |
|
12 | +require_once __DIR__.'/lib/consts.inc.php'; |
|
13 | 13 | $opt['gui'] = GUI_HTML; |
14 | -require_once __DIR__ . '/lib/common.inc.php'; |
|
15 | -require_once __DIR__ . '/lib2/edithelper.inc.php'; |
|
14 | +require_once __DIR__.'/lib/common.inc.php'; |
|
15 | +require_once __DIR__.'/lib2/edithelper.inc.php'; |
|
16 | 16 | |
17 | 17 | //Preprocessing |
18 | 18 | if ($error == false) { |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | $tplname = 'login'; |
27 | 27 | |
28 | 28 | tpl_set_var('username', ''); |
29 | - tpl_set_var('target', htmlspecialchars('newdesc.php?cacheid=' . urlencode($cache_id), ENT_COMPAT, 'UTF-8')); |
|
29 | + tpl_set_var('target', htmlspecialchars('newdesc.php?cacheid='.urlencode($cache_id), ENT_COMPAT, 'UTF-8')); |
|
30 | 30 | tpl_set_var('message', $login_required); |
31 | 31 | tpl_set_var('helplink', helppagelink('login')); |
32 | 32 | } else { |
@@ -40,15 +40,15 @@ discard block |
||
40 | 40 | if ($cache_record['user_id'] == $usr['userid']) { |
41 | 41 | $tplname = 'newdesc'; |
42 | 42 | |
43 | - require $stylepath . '/newdesc.inc.php'; |
|
43 | + require $stylepath.'/newdesc.inc.php'; |
|
44 | 44 | |
45 | 45 | //get the posted data |
46 | 46 | $show_all_langs = isset($_POST['show_all_langs']) ? $_POST['show_all_langs'] : 0; |
47 | - $short_desc = isset($_POST['short_desc']) ? $_POST['short_desc'] : ''; // Ocprop |
|
47 | + $short_desc = isset($_POST['short_desc']) ? $_POST['short_desc'] : ''; // Ocprop |
|
48 | 48 | |
49 | - $hints = isset($_POST['hints']) ? $_POST['hints'] : ''; // Ocprop |
|
50 | - $sel_lang = isset($_POST['desc_lang']) ? $_POST['desc_lang'] : $default_lang; // Ocprop |
|
51 | - $desc = isset($_POST['desc']) ? $_POST['desc'] : ''; // Ocprop |
|
49 | + $hints = isset($_POST['hints']) ? $_POST['hints'] : ''; // Ocprop |
|
50 | + $sel_lang = isset($_POST['desc_lang']) ? $_POST['desc_lang'] : $default_lang; // Ocprop |
|
51 | + $desc = isset($_POST['desc']) ? $_POST['desc'] : ''; // Ocprop |
|
52 | 52 | |
53 | 53 | // read descMode; if not set, initialize from user profile |
54 | 54 | if (isset($_POST['descMode'])) { // Ocprop |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | $oldDescMode = $descMode; |
66 | 66 | } |
67 | 67 | } else { |
68 | - if (sqlValue("SELECT `no_htmledit_flag` FROM `user` WHERE `user_id`='" . sql_escape($usr['userid']) . "'", 1) == 1) { |
|
68 | + if (sqlValue("SELECT `no_htmledit_flag` FROM `user` WHERE `user_id`='".sql_escape($usr['userid'])."'", 1) == 1) { |
|
69 | 69 | $descMode = 1; |
70 | 70 | } else { |
71 | 71 | $descMode = 3; |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | // do not use slave server for the next time ... |
129 | 129 | db_slave_exclude(); |
130 | 130 | |
131 | - tpl_redirect('editcache.php?cacheid=' . urlencode($cache_id)); |
|
131 | + tpl_redirect('editcache.php?cacheid='.urlencode($cache_id)); |
|
132 | 132 | exit; |
133 | 133 | } |
134 | 134 | } elseif (isset($_POST['show_all_langs_submit'])) { |
@@ -142,8 +142,8 @@ discard block |
||
142 | 142 | FROM `languages_list_default` |
143 | 143 | LEFT JOIN `cache_desc` |
144 | 144 | ON `languages_list_default`.`show`=`cache_desc`.`language` |
145 | - AND `cache_desc`.`cache_id`='" . sql_escape($cache_id) . "' |
|
146 | - WHERE `languages_list_default`.`lang`='" . sql_escape($locale) . "' |
|
145 | + AND `cache_desc`.`cache_id`='" . sql_escape($cache_id)."' |
|
146 | + WHERE `languages_list_default`.`lang`='" . sql_escape($locale)."' |
|
147 | 147 | AND ISNULL(`cache_desc`.`cache_id`)", 0) == 0 |
148 | 148 | ) { |
149 | 149 | $show_all_langs = 1; |
@@ -179,13 +179,13 @@ discard block |
||
179 | 179 | if ($sSelected != '') { |
180 | 180 | $selected = true; |
181 | 181 | } |
182 | - $langoptions .= '<option value="' . htmlspecialchars($rLanguage['short'], ENT_COMPAT, 'UTF-8') . '"' . $sSelected . '>' . htmlspecialchars($rLanguage['name'], ENT_COMPAT, 'UTF-8') . '</option>' . "\n"; |
|
182 | + $langoptions .= '<option value="'.htmlspecialchars($rLanguage['short'], ENT_COMPAT, 'UTF-8').'"'.$sSelected.'>'.htmlspecialchars($rLanguage['name'], ENT_COMPAT, 'UTF-8').'</option>'."\n"; |
|
183 | 183 | } |
184 | 184 | sql_free_result($rsLanguages); |
185 | 185 | if ($langoptions == '') { |
186 | 186 | // We get here if someone has added descriptions for all avaiable languages, which |
187 | 187 | // is very unlikely to happen ever. Just for completeness (see issue #108): |
188 | - tpl_redirect('editcache.php?cacheid=' . urlencode($cache_id)); |
|
188 | + tpl_redirect('editcache.php?cacheid='.urlencode($cache_id)); |
|
189 | 189 | } |
190 | 190 | |
191 | 191 | tpl_set_var('langoptions', $langoptions); |
@@ -195,8 +195,7 @@ discard block |
||
195 | 195 | tpl_set_var('name', htmlspecialchars($cache_record['name'], ENT_COMPAT, 'UTF-8')); |
196 | 196 | tpl_set_var('cacheid', htmlspecialchars($cache_id, ENT_COMPAT, 'UTF-8')); |
197 | 197 | |
198 | - tpl_set_var('lang_message', $desc_lang_exists ? $lang_message : |
|
199 | - (isset($_POST['submitform']) && $sel_lang == '0' ? $error_no_lang_selected : '')); |
|
198 | + tpl_set_var('lang_message', $desc_lang_exists ? $lang_message : (isset($_POST['submitform']) && $sel_lang == '0' ? $error_no_lang_selected : '')); |
|
200 | 199 | |
201 | 200 | tpl_set_var('show_all_langs', $show_all_langs); |
202 | 201 | tpl_set_var('show_all_langs_submit', ($show_all_langs == 0) ? $show_all_langs_submit : ''); |
@@ -209,16 +208,16 @@ discard block |
||
209 | 208 | tpl_set_var('descMode', $descMode); |
210 | 209 | tpl_set_var('htmlnotice', $descMode == 2 ? $htmlnotice : ''); |
211 | 210 | |
212 | - $headers = tpl_get_var('htmlheaders') . "\n"; |
|
211 | + $headers = tpl_get_var('htmlheaders')."\n"; |
|
213 | 212 | if ($descMode == 3) { |
214 | 213 | // TinyMCE |
215 | - $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/tiny_mce_gzip.js"></script>' . "\n"; |
|
216 | - $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/config/desc.js.php?cacheid=' . ($cache_id + 0) . '&lang=' . strtolower($locale) . '"></script>' . "\n"; |
|
214 | + $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/tiny_mce_gzip.js"></script>'."\n"; |
|
215 | + $headers .= '<script language="javascript" type="text/javascript" src="resource2/tinymce/config/desc.js.php?cacheid='.($cache_id + 0).'&lang='.strtolower($locale).'"></script>'."\n"; |
|
217 | 216 | } |
218 | - $headers .= '<script language="javascript" type="text/javascript" src="' . editorJsPath() . '"></script>' . "\n"; |
|
217 | + $headers .= '<script language="javascript" type="text/javascript" src="'.editorJsPath().'"></script>'."\n"; |
|
219 | 218 | tpl_set_var('htmlheaders', $headers); |
220 | 219 | |
221 | - tpl_set_var('reset', $reset); // obsolete |
|
220 | + tpl_set_var('reset', $reset); // obsolete |
|
222 | 221 | tpl_set_var('submit', $submit); |
223 | 222 | } else { |
224 | 223 | //TODO: not the owner |
@@ -5,7 +5,7 @@ discard block |
||
5 | 5 | * Unicode Reminder メモ |
6 | 6 | ***************************************************************************/ |
7 | 7 | |
8 | -require __DIR__ . '/lib2/web.inc.php'; |
|
8 | +require __DIR__.'/lib2/web.inc.php'; |
|
9 | 9 | |
10 | 10 | $tpl->name = 'adoptcache'; |
11 | 11 | $tpl->menuitem = MNU_CACHES_ADOPT; |
@@ -173,7 +173,7 @@ discard block |
||
173 | 173 | |
174 | 174 | $adopt_result = $cache->addAdoption($userid); |
175 | 175 | if ($adopt_result === true) { |
176 | - $tpl->redirect('adoptcache.php?action=listbycache&cacheid=' . $cacheid); |
|
176 | + $tpl->redirect('adoptcache.php?action=listbycache&cacheid='.$cacheid); |
|
177 | 177 | } else { |
178 | 178 | $tpl->assign('error', $adopt_result); |
179 | 179 | listRequestsByCacheId($cacheid); |
@@ -194,7 +194,7 @@ discard block |
||
194 | 194 | $tpl->error(ERROR_UNKNOWN); |
195 | 195 | } |
196 | 196 | |
197 | - $tpl->redirect('viewcache.php?cacheid=' . $cacheid); |
|
197 | + $tpl->redirect('viewcache.php?cacheid='.$cacheid); |
|
198 | 198 | } |
199 | 199 | |
200 | 200 | function cancelRequest($cacheid, $userid) |
@@ -218,6 +218,6 @@ discard block |
||
218 | 218 | if ($userid == $login->userid) { |
219 | 219 | $tpl->redirect('adoptcache.php'); |
220 | 220 | } else { |
221 | - $tpl->redirect('adoptcache.php?action=listbycache&cacheid=' . $cacheid); |
|
221 | + $tpl->redirect('adoptcache.php?action=listbycache&cacheid='.$cacheid); |
|
222 | 222 | } |
223 | 223 | } |