@@ -65,10 +65,10 @@ |
||
65 | 65 | $member_info = array(); |
66 | 66 | } |
67 | 67 | foreach ($infos as $info) { |
68 | - if (!array_key_exists($info, $member_info) && @$_SESSION['xoops_member_info'][$info . '_expire'] < $time) { |
|
68 | + if (!array_key_exists($info, $member_info) && @$_SESSION['xoops_member_info'][$info.'_expire'] < $time) { |
|
69 | 69 | $member_info[$info] = $xoops->user->getVar($info, 'E'); |
70 | 70 | $_SESSION['xoops_member_info'][$info] = $member_info[$info]; |
71 | - $_SESSION['xoops_member_info'][$info . '_expire'] = $time + 60; |
|
71 | + $_SESSION['xoops_member_info'][$info.'_expire'] = $time + 60; |
|
72 | 72 | } |
73 | 73 | } |
74 | 74 | } |
@@ -26,7 +26,7 @@ |
||
26 | 26 | function smarty_block_noshortcodes($params, $content, $template, &$repeat) |
27 | 27 | { |
28 | 28 | // only output on the closing tag |
29 | - if(!$repeat){ |
|
29 | + if (!$repeat) { |
|
30 | 30 | if (isset($content)) { |
31 | 31 | $ts = \Xoops\Core\Text\Sanitizer::getInstance(); |
32 | 32 | return $ts->escapeShortCodes($content); |
@@ -7,7 +7,7 @@ discard block |
||
7 | 7 | $shortcodes = \Xoops\Core\Text\Sanitizer::getInstance()->getShortCodes(); |
8 | 8 | $shortcodes->addShortcode( |
9 | 9 | 'nosc42', |
10 | - function ($attributes, $content, $tagName) { |
|
10 | + function($attributes, $content, $tagName) { |
|
11 | 11 | return base64_decode($content); |
12 | 12 | } |
13 | 13 | ); |
@@ -17,13 +17,13 @@ discard block |
||
17 | 17 | |
18 | 18 | $text = preg_replace_callback( |
19 | 19 | $scPattern, |
20 | - function ($innerMatches) { |
|
21 | - return '[nosc42]' . base64_encode($innerMatches[1]) . '[/nosc42]'; |
|
20 | + function($innerMatches) { |
|
21 | + return '[nosc42]'.base64_encode($innerMatches[1]).'[/nosc42]'; |
|
22 | 22 | }, |
23 | 23 | $output |
24 | 24 | ); |
25 | - if ($text===null) { |
|
26 | - trigger_error('preg_last_error=' . preg_last_error(), E_USER_WARNING); |
|
25 | + if ($text === null) { |
|
26 | + trigger_error('preg_last_error='.preg_last_error(), E_USER_WARNING); |
|
27 | 27 | return $output; |
28 | 28 | } |
29 | 29 |
@@ -22,13 +22,13 @@ |
||
22 | 22 | $xoops = Xoops::getInstance(); |
23 | 23 | |
24 | 24 | if (XoopsLoad::fileExists($xoops->path('media/xoops/images/icons/bookmarks/index.html'))) { |
25 | - $url = $xoops->url('media/xoops/images/icons/bookmarks/' . $argStr); |
|
25 | + $url = $xoops->url('media/xoops/images/icons/bookmarks/'.$argStr); |
|
26 | 26 | } else { |
27 | - if (XoopsLoad::fileExists($xoops->path('modules/system/images/icons/default/' . $argStr))) { |
|
28 | - $url = $xoops->url('modules/system/images/icons/default/' . $argStr); |
|
27 | + if (XoopsLoad::fileExists($xoops->path('modules/system/images/icons/default/'.$argStr))) { |
|
28 | + $url = $xoops->url('modules/system/images/icons/default/'.$argStr); |
|
29 | 29 | } else { |
30 | 30 | $url = $xoops->url('modules/system/images/icons/default/xoops/xoops.png'); |
31 | 31 | } |
32 | 32 | } |
33 | - return "\necho '" . addslashes($url) . "';"; |
|
33 | + return "\necho '".addslashes($url)."';"; |
|
34 | 34 | } |
@@ -24,13 +24,13 @@ |
||
24 | 24 | $ico = trim($arg, " '\"\t\n\r\0\x0B"); |
25 | 25 | |
26 | 26 | if (XoopsLoad::fileExists($xoops->path('media/xoops/images/icons/16/index.html'))) { |
27 | - $url = $xoops->url('media/xoops/images/icons/16/' . $ico); |
|
27 | + $url = $xoops->url('media/xoops/images/icons/16/'.$ico); |
|
28 | 28 | } else { |
29 | - if (XoopsLoad::fileExists($xoops->path('modules/system/images/icons/default/' . $ico))) { |
|
30 | - $url = $xoops->url('modules/system/images/icons/default/' . $ico); |
|
29 | + if (XoopsLoad::fileExists($xoops->path('modules/system/images/icons/default/'.$ico))) { |
|
30 | + $url = $xoops->url('modules/system/images/icons/default/'.$ico); |
|
31 | 31 | } else { |
32 | 32 | $url = $xoops->url('modules/system/images/icons/default/xoops/xoops2.png'); |
33 | 33 | } |
34 | 34 | } |
35 | - return "<?php echo '" . addslashes($url) . "'; ?>"; |
|
35 | + return "<?php echo '".addslashes($url)."'; ?>"; |
|
36 | 36 | } |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | $urlstr = "$urlstr&{$var['name']}={$var['value']}"; |
74 | 74 | } |
75 | 75 | if (strlen($urlstr) > 0) { |
76 | - $urlstr = '?' . substr($urlstr, 1); |
|
76 | + $urlstr = '?'.substr($urlstr, 1); |
|
77 | 77 | } |
78 | 78 | } |
79 | 79 | |
@@ -94,8 +94,8 @@ discard block |
||
94 | 94 | } |
95 | 95 | // Now, return entire link URL :-) |
96 | 96 | if (empty($module)) { |
97 | - echo $xoops->url($page . $urlstr); |
|
97 | + echo $xoops->url($page.$urlstr); |
|
98 | 98 | } else { |
99 | - echo $xoops->url("modules/{$module}/{$page}" . $urlstr); |
|
99 | + echo $xoops->url("modules/{$module}/{$page}".$urlstr); |
|
100 | 100 | } |
101 | 101 | } |
@@ -28,14 +28,14 @@ |
||
28 | 28 | $arg = reset($params); |
29 | 29 | $ico = trim($arg, " '\"\t\n\r\0\x0B"); |
30 | 30 | |
31 | - if (XoopsLoad::fileExists($xoops->path('media/xoops/images/icons/32/' . $icons . '/index.html'))) { |
|
32 | - $url = $xoops->url('media/xoops/images/icons/32/' . $icons . '/' . $ico); |
|
31 | + if (XoopsLoad::fileExists($xoops->path('media/xoops/images/icons/32/'.$icons.'/index.html'))) { |
|
32 | + $url = $xoops->url('media/xoops/images/icons/32/'.$icons.'/'.$ico); |
|
33 | 33 | } else { |
34 | - if (XoopsLoad::fileExists($xoops->path('modules/system/images/icons/default/' . $ico))) { |
|
35 | - $url = $xoops->url('modules/system/images/icons/default/' . $ico); |
|
34 | + if (XoopsLoad::fileExists($xoops->path('modules/system/images/icons/default/'.$ico))) { |
|
35 | + $url = $xoops->url('modules/system/images/icons/default/'.$ico); |
|
36 | 36 | } else { |
37 | 37 | $url = $xoops->url('modules/system/images/icons/default/xoops/xoops.png'); |
38 | 38 | } |
39 | 39 | } |
40 | - return "<?php echo '" . addslashes($url) . "'; ?>"; |
|
40 | + return "<?php echo '".addslashes($url)."'; ?>"; |
|
41 | 41 | } |
@@ -5,11 +5,11 @@ discard block |
||
5 | 5 | //todo, check this file |
6 | 6 | $path = '/path/to/xoops/directory'; |
7 | 7 | |
8 | -include $path . '/mainfile.php'; |
|
8 | +include $path.'/mainfile.php'; |
|
9 | 9 | if (!defined('XOOPS_ROOT_PATH')) { |
10 | 10 | exit(); |
11 | 11 | } |
12 | -include_once XOOPS_ROOT_PATH . '/language/' . $xoopsConfig['language'] . '/user.php'; |
|
12 | +include_once XOOPS_ROOT_PATH.'/language/'.$xoopsConfig['language'].'/user.php'; |
|
13 | 13 | $op = (isset($_POST['op']) && $_POST['op'] == 'dologin') ? 'dologin' : 'login'; |
14 | 14 | |
15 | 15 | $username = isset($_POST['username']) ? trim($_POST['username']) : ''; |
@@ -21,17 +21,17 @@ discard block |
||
21 | 21 | echo ' |
22 | 22 | <html> |
23 | 23 | <head> |
24 | - <meta http-equiv="content-type" content="text/html; charset=' . XoopsLocale::getCharset() . '" /> |
|
25 | - <meta http-equiv="content-language" content="' . XoopsLocale::getLangCode() . '" /> |
|
26 | - <title>' . $xoopsConfig['sitename'] . '</title> |
|
27 | - <link rel="stylesheet" type="text/css" media="all" href="' . XOOPS_URL . '/xoops.css" /> |
|
24 | + <meta http-equiv="content-type" content="text/html; charset=' . XoopsLocale::getCharset().'" /> |
|
25 | + <meta http-equiv="content-language" content="' . XoopsLocale::getLangCode().'" /> |
|
26 | + <title>' . $xoopsConfig['sitename'].'</title> |
|
27 | + <link rel="stylesheet" type="text/css" media="all" href="' . XOOPS_URL.'/xoops.css" /> |
|
28 | 28 | '; |
29 | 29 | $style = xoops_getcss($xoopsConfig['theme_set']); |
30 | 30 | if ($style == '') { |
31 | 31 | $style = xoops_getcss($xoopsConfig['theme_set']); |
32 | 32 | } |
33 | 33 | if ($style != '') { |
34 | - echo '<link rel="stylesheet" type="text/css" media="all" href="' . $style . '" />'; |
|
34 | + echo '<link rel="stylesheet" type="text/css" media="all" href="'.$style.'" />'; |
|
35 | 35 | } |
36 | 36 | echo ' |
37 | 37 | </head> |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | $user = $member_handler->loginUser($username, $password); |
45 | 45 | if (is_object($user)) { |
46 | 46 | if (0 == $user->getVar('level')) { |
47 | - redirect_header(XOOPS_URL . '/index.php', 5, XoopsLocale::E_SELECTED_USER_DEACTIVATED_OR_NOT_ACTIVE); |
|
47 | + redirect_header(XOOPS_URL.'/index.php', 5, XoopsLocale::E_SELECTED_USER_DEACTIVATED_OR_NOT_ACTIVE); |
|
48 | 48 | exit(); |
49 | 49 | } |
50 | 50 | if ($xoopsConfig['closesite'] == 1) { |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | } |
57 | 57 | } |
58 | 58 | if (!$allowed) { |
59 | - redirect_header(XOOPS_URL . '/index.php', 1, XoopsLocale::E_NO_ACCESS_PERMISSION); |
|
59 | + redirect_header(XOOPS_URL.'/index.php', 1, XoopsLocale::E_NO_ACCESS_PERMISSION); |
|
60 | 60 | exit(); |
61 | 61 | } |
62 | 62 | } |
@@ -67,13 +67,13 @@ discard block |
||
67 | 67 | $_SESSION['xoopsUserId'] = $user->getVar('uid'); |
68 | 68 | $_SESSION['xoopsUserGroups'] = $user->getGroups(); |
69 | 69 | if (!empty($xoopsConfig['use_ssl'])) { |
70 | - xoops_confirm(array($xoopsConfig['sslpost_name'] => session_id()), XOOPS_URL . '/misc.php?action=showpopups&type=ssllogin', XoopsLocale::PRESS_BUTTON_BELLOW_TO_LOGIN, XoopsLocale::A_LOGIN); |
|
70 | + xoops_confirm(array($xoopsConfig['sslpost_name'] => session_id()), XOOPS_URL.'/misc.php?action=showpopups&type=ssllogin', XoopsLocale::PRESS_BUTTON_BELLOW_TO_LOGIN, XoopsLocale::A_LOGIN); |
|
71 | 71 | } else { |
72 | 72 | echo sprintf(XoopsLocale::SF_THANK_YOU_FOR_LOGGING_IN, $user->getVar('uname')); |
73 | - echo '<div style="text-align:center;"><input value="' . XoopsLocale::A_CLOSE . '" type="button" onclick="document.window.opener.location.reload();document.window.close();" /></div>'; |
|
73 | + echo '<div style="text-align:center;"><input value="'.XoopsLocale::A_CLOSE.'" type="button" onclick="document.window.opener.location.reload();document.window.close();" /></div>'; |
|
74 | 74 | } |
75 | 75 | } else { |
76 | - xoops_error(XoopsLocale::E_INCORRECT_LOGIN . '<br /><a href="login.php">' . XoopsLocale::GO_BACK . '</a>'); |
|
76 | + xoops_error(XoopsLocale::E_INCORRECT_LOGIN.'<br /><a href="login.php">'.XoopsLocale::GO_BACK.'</a>'); |
|
77 | 77 | } |
78 | 78 | } |
79 | 79 | |
@@ -83,16 +83,16 @@ discard block |
||
83 | 83 | <form action="login.php" method="post"> |
84 | 84 | <table class="outer" width="95%"> |
85 | 85 | <tr> |
86 | - <td class="head">' . XoopsLocale::C_USERNAME . '</td> |
|
86 | + <td class="head">' . XoopsLocale::C_USERNAME.'</td> |
|
87 | 87 | <td class="even"><input type="text" name="username" value="" /></td> |
88 | 88 | </tr> |
89 | 89 | <tr> |
90 | - <td class="head">' . XoopsLocale::C_PASSWORD . '</td> |
|
90 | + <td class="head">' . XoopsLocale::C_PASSWORD.'</td> |
|
91 | 91 | <td class="even"><input type="password" name="userpass" value="" /></td> |
92 | 92 | </tr> |
93 | 93 | <tr> |
94 | 94 | <td class="head"> </td> |
95 | - <td class="even"><input type="hidden" name="op" value="dologin" /><input type="submit" name="submit" value="' . XoopsLocale::A_LOGIN . '" /></td> |
|
95 | + <td class="even"><input type="hidden" name="op" value="dologin" /><input type="submit" name="submit" value="' . XoopsLocale::A_LOGIN.'" /></td> |
|
96 | 96 | </tr> |
97 | 97 | </table> |
98 | 98 | </form> |
@@ -25,14 +25,14 @@ discard block |
||
25 | 25 | global $xoopsModule, $xoopsConfig, $mydirname, $mydirpath, $mytrustdirname, $mytrustdirpath, $mymenu_fake_uri; |
26 | 26 | |
27 | 27 | $mymenu_find_paths = array( |
28 | - $mydirpath . '/admin/mymenu.php', $mydirpath . '/mymenu.php', $mytrustdirpath . '/admin/mymenu.php', |
|
29 | - $mytrustdirpath . '/mymenu.php', |
|
28 | + $mydirpath.'/admin/mymenu.php', $mydirpath.'/mymenu.php', $mytrustdirpath.'/admin/mymenu.php', |
|
29 | + $mytrustdirpath.'/mymenu.php', |
|
30 | 30 | ); |
31 | 31 | |
32 | 32 | foreach ($mymenu_find_paths as $mymenu_find_path) { |
33 | 33 | if (file_exists($mymenu_find_path)) { |
34 | 34 | include $mymenu_find_path; |
35 | - include_once dirname(__FILE__) . '/adminmenu_functions.php'; |
|
35 | + include_once dirname(__FILE__).'/adminmenu_functions.php'; |
|
36 | 36 | altsys_adminmenu_insert_mymenu($xoopsModule); |
37 | 37 | altsys_adminmenu_hack_ft(); |
38 | 38 | break; |
@@ -45,17 +45,17 @@ discard block |
||
45 | 45 | { |
46 | 46 | $mylang = Xoops::getInstance()->getConfig('language'); |
47 | 47 | |
48 | - if (file_exists(XOOPS_ROOT_PATH . '/modules/altsys/language/' . $mylang . '/' . $type . '.php')) { |
|
49 | - include_once XOOPS_ROOT_PATH . '/modules/altsys/language/' . $mylang . '/' . $type . '.php'; |
|
48 | + if (file_exists(XOOPS_ROOT_PATH.'/modules/altsys/language/'.$mylang.'/'.$type.'.php')) { |
|
49 | + include_once XOOPS_ROOT_PATH.'/modules/altsys/language/'.$mylang.'/'.$type.'.php'; |
|
50 | 50 | } else { |
51 | - if (file_exists(XOOPS_TRUST_PATH . '/libs/altsys/language/' . $mylang . '/' . $type . '.php')) { |
|
52 | - include_once XOOPS_TRUST_PATH . '/libs/altsys/language/' . $mylang . '/' . $type . '.php'; |
|
51 | + if (file_exists(XOOPS_TRUST_PATH.'/libs/altsys/language/'.$mylang.'/'.$type.'.php')) { |
|
52 | + include_once XOOPS_TRUST_PATH.'/libs/altsys/language/'.$mylang.'/'.$type.'.php'; |
|
53 | 53 | } else { |
54 | - if (file_exists(XOOPS_ROOT_PATH . '/modules/altsys/language/english/' . $type . '.php')) { |
|
55 | - include_once XOOPS_ROOT_PATH . '/modules/altsys/language/english/' . $type . '.php'; |
|
54 | + if (file_exists(XOOPS_ROOT_PATH.'/modules/altsys/language/english/'.$type.'.php')) { |
|
55 | + include_once XOOPS_ROOT_PATH.'/modules/altsys/language/english/'.$type.'.php'; |
|
56 | 56 | } else { |
57 | - if (file_exists(XOOPS_TRUST_PATH . '/libs/altsys/language/english/' . $type . '.php')) { |
|
58 | - include_once XOOPS_TRUST_PATH . '/libs/altsys/language/english/' . $type . '.php'; |
|
57 | + if (file_exists(XOOPS_TRUST_PATH.'/libs/altsys/language/english/'.$type.'.php')) { |
|
58 | + include_once XOOPS_TRUST_PATH.'/libs/altsys/language/english/'.$type.'.php'; |
|
59 | 59 | } |
60 | 60 | } |
61 | 61 | } |
@@ -103,9 +103,9 @@ discard block |
||
103 | 103 | case ALTSYS_CORE_TYPE_X20S : |
104 | 104 | case ALTSYS_CORE_TYPE_ORE : |
105 | 105 | case ALTSYS_CORE_TYPE_X22 : |
106 | - return XOOPS_URL . '/modules/system/admin.php?fct=preferences&op=showmod&mod=' . $mid; |
|
106 | + return XOOPS_URL.'/modules/system/admin.php?fct=preferences&op=showmod&mod='.$mid; |
|
107 | 107 | case ALTSYS_CORE_TYPE_XC21L : |
108 | - return XOOPS_URL . '/modules/legacy/admin/index.php?action=PreferenceEdit&confmod_id=' . $mid; |
|
108 | + return XOOPS_URL.'/modules/legacy/admin/index.php?action=PreferenceEdit&confmod_id='.$mid; |
|
109 | 109 | } |
110 | 110 | } |
111 | 111 | |
@@ -132,7 +132,7 @@ discard block |
||
132 | 132 | if (substr($file, -4) != '.php') { |
133 | 133 | continue; |
134 | 134 | } |
135 | - @unlink(XOOPS_COMPILE_PATH . '/' . $file); |
|
135 | + @unlink(XOOPS_COMPILE_PATH.'/'.$file); |
|
136 | 136 | } |
137 | 137 | closedir($dh); |
138 | 138 | } |