Completed
Push — master ( b4f428...a74d38 )
by Michael
02:21
created
xoops_trust_path/libs/altsys/blocks/block_functions.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -1,6 +1,6 @@  discard block
 block discarded – undo
1 1
 <?php
2 2
 
3
-require_once dirname(__DIR__) . '/include/altsys_functions.php';
3
+require_once dirname(__DIR__).'/include/altsys_functions.php';
4 4
 
5 5
 /**
6 6
  * @param $options
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
 
13 13
     $mydirname = empty($options[0]) ? 'altsys' : $options[0];
14 14
 
15
-    $this_template = empty($options[1]) ? 'db:' . $mydirname . '_block_admin_menu.tpl' : trim($options[1]);
15
+    $this_template = empty($options[1]) ? 'db:'.$mydirname.'_block_admin_menu.tpl' : trim($options[1]);
16 16
 
17 17
     if (preg_match('/[^0-9a-zA-Z_-]/', $mydirname)) {
18 18
         die('Invalid mydirname');
@@ -56,12 +56,12 @@  discard block
 block discarded – undo
56 56
 
57 57
     $admin_mids = $moduleperm_handler->getItemIds('module_admin', $xoopsUser->getGroups());
58 58
 
59
-    $modules = $module_handler->getObjects(new Criteria('mid', '(' . implode(',', $admin_mids) . ')', 'IN'), true);
59
+    $modules = $module_handler->getObjects(new Criteria('mid', '('.implode(',', $admin_mids).')', 'IN'), true);
60 60
 
61 61
     $block = [
62 62
         'mydirname' => $mydirname,
63
-        'mod_url' => XOOPS_URL . '/modules/' . $mydirname,
64
-        'mod_imageurl' => XOOPS_URL . '/modules/' . $mydirname . '/' . $current_configs['images_dir'],
63
+        'mod_url' => XOOPS_URL.'/modules/'.$mydirname,
64
+        'mod_imageurl' => XOOPS_URL.'/modules/'.$mydirname.'/'.$current_configs['images_dir'],
65 65
         'mod_config' => $current_configs,
66 66
     ];
67 67
 
@@ -80,7 +80,7 @@  discard block
 block discarded – undo
80 80
 
81 81
         unset($adminmenu_use_altsys);
82 82
 
83
-        @include XOOPS_ROOT_PATH . '/modules/' . $dirname . '/' . @$modinfo['adminmenu'];
83
+        @include XOOPS_ROOT_PATH.'/modules/'.$dirname.'/'.@$modinfo['adminmenu'];
84 84
 
85 85
         // from admin_menu.php etc.
86 86
 
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
 
96 96
             $submenus4assign[] = [
97 97
                 'title' => htmlspecialchars($sub['title']),
98
-                'url' => XOOPS_URL . '/modules/' . $dirname . '/' . htmlspecialchars($link, ENT_QUOTES),
98
+                'url' => XOOPS_URL.'/modules/'.$dirname.'/'.htmlspecialchars($link, ENT_QUOTES),
99 99
             ];
100 100
         }
101 101
 
@@ -119,7 +119,7 @@  discard block
 block discarded – undo
119 119
 
120 120
                 $submenus4assign[] = [
121 121
                     'title' => htmlspecialchars($sub['title']),
122
-                    'url' => 0 === strncmp($sub['link'], 'http', 4) ? htmlspecialchars($sub['link'], ENT_QUOTES) : XOOPS_URL . '/modules/' . $dirname . '/' . htmlspecialchars($sub['link'], ENT_QUOTES),
122
+                    'url' => 0 === strncmp($sub['link'], 'http', 4) ? htmlspecialchars($sub['link'], ENT_QUOTES) : XOOPS_URL.'/modules/'.$dirname.'/'.htmlspecialchars($sub['link'], ENT_QUOTES),
123 123
                 ];
124 124
             }
125 125
         } elseif (empty($adminmenu4altsys)) {
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
             if (defined('XOOPS_CUBE_LEGACY') && !empty($modinfo['help'])) {
138 138
                 $submenus4assign[] = [
139 139
                     'title' => _HELP,
140
-                    'url' => XOOPS_URL . '/modules/legacy/admin/index.php?action=Help&amp;dirname=' . $dirname,
140
+                    'url' => XOOPS_URL.'/modules/legacy/admin/index.php?action=Help&amp;dirname='.$dirname,
141 141
                 ];
142 142
             }
143 143
         }
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
         $block['modules'][] = $module4assign;
166 166
     }
167 167
 
168
-    require_once XOOPS_TRUST_PATH . '/libs/altsys/class/D3Tpl.class.php';
168
+    require_once XOOPS_TRUST_PATH.'/libs/altsys/class/D3Tpl.class.php';
169 169
 
170 170
     $tpl = new D3Tpl();
171 171
 
@@ -184,7 +184,7 @@  discard block
 block discarded – undo
184 184
 {
185 185
     $mydirname = empty($options[0]) ? 'd3forum' : $options[0];
186 186
 
187
-    $this_template = empty($options[1]) ? 'db:' . $mydirname . '_block_admin_menu.tpl' : trim($options[1]);
187
+    $this_template = empty($options[1]) ? 'db:'.$mydirname.'_block_admin_menu.tpl' : trim($options[1]);
188 188
 
189 189
     if (preg_match('/[^0-9a-zA-Z_-]/', $mydirname)) {
190 190
         die('Invalid mydirname');
@@ -192,8 +192,8 @@  discard block
 block discarded – undo
192 192
 
193 193
     $form = "
194 194
         <input type='hidden' name='options[0]' value='$mydirname' />
195
-        <label for='this_template'>" . _MB_ALTSYS_THISTEMPLATE . "</label>&nbsp;:
196
-        <input type='text' size='60' name='options[1]' id='this_template' value='" . htmlspecialchars($this_template, ENT_QUOTES) . "' />
195
+        <label for='this_template'>"._MB_ALTSYS_THISTEMPLATE."</label>&nbsp;:
196
+        <input type='text' size='60' name='options[1]' id='this_template' value='" . htmlspecialchars($this_template, ENT_QUOTES)."' />
197 197
         <br />
198 198
     \n";
199 199
 
Please login to merge, or discard this patch.
xoops_trust_path/libs/altsys/language/ja_utf8/blocks_each.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,10 +3,10 @@
 block discarded – undo
3 3
 if (defined('FOR_XOOPS_LANG_CHECKER')) {
4 4
     $mydirname = 'd3forum';
5 5
 }
6
-$constpref = '_MB_' . mb_strtoupper($mydirname);
6
+$constpref = '_MB_'.mb_strtoupper($mydirname);
7 7
 
8
-if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref . '_LOADED')) {
9
-    define($constpref . '_LOADED', 1);
8
+if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref.'_LOADED')) {
9
+    define($constpref.'_LOADED', 1);
10 10
 
11 11
     // definitions for displaying blocks
12 12
     // Since altsys is a singleton moudle, this file has non-sense.
Please login to merge, or discard this patch.
xoops_trust_path/libs/altsys/language/spanish/blocks_each.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,10 +3,10 @@
 block discarded – undo
3 3
 if (defined('FOR_XOOPS_LANG_CHECKER')) {
4 4
     $mydirname = 'd3forum';
5 5
 }
6
-$constpref = '_MB_' . mb_strtoupper($mydirname);
6
+$constpref = '_MB_'.mb_strtoupper($mydirname);
7 7
 
8
-if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref . '_LOADED')) {
9
-    define($constpref . '_LOADED', 1);
8
+if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref.'_LOADED')) {
9
+    define($constpref.'_LOADED', 1);
10 10
 
11 11
     // definitions for displaying blocks
12 12
     // Since altsys is a singleton moudle, this file has non-sense.
Please login to merge, or discard this patch.
xoops_trust_path/libs/altsys/language/persian/blocks_each.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,10 +3,10 @@
 block discarded – undo
3 3
 if (defined('FOR_XOOPS_LANG_CHECKER')) {
4 4
     $mydirname = 'd3forum';
5 5
 }
6
-$constpref = '_MB_' . mb_strtoupper($mydirname);
6
+$constpref = '_MB_'.mb_strtoupper($mydirname);
7 7
 
8
-if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref . '_LOADED')) {
9
-    define($constpref . '_LOADED', 1);
8
+if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref.'_LOADED')) {
9
+    define($constpref.'_LOADED', 1);
10 10
 
11 11
     // definitions for displaying blocks
12 12
     // Since altsys is a singleton moudle, this file has non-sense.
Please login to merge, or discard this patch.
xoops_trust_path/libs/altsys/language/english/blocks_each.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,10 +3,10 @@
 block discarded – undo
3 3
 if (defined('FOR_XOOPS_LANG_CHECKER')) {
4 4
     $mydirname = 'd3forum';
5 5
 }
6
-$constpref = '_MB_' . mb_strtoupper($mydirname);
6
+$constpref = '_MB_'.mb_strtoupper($mydirname);
7 7
 
8
-if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref . '_LOADED')) {
9
-    define($constpref . '_LOADED', 1);
8
+if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref.'_LOADED')) {
9
+    define($constpref.'_LOADED', 1);
10 10
 
11 11
     // definitions for displaying blocks
12 12
     // Since altsys is a singleton moudle, this file has non-sense.
Please login to merge, or discard this patch.
xoops_trust_path/libs/altsys/language/french/blocks_each.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -3,10 +3,10 @@
 block discarded – undo
3 3
 if (defined('FOR_XOOPS_LANG_CHECKER')) {
4 4
     $mydirname = 'd3forum';
5 5
 }
6
-$constpref = '_MB_' . mb_strtoupper($mydirname);
6
+$constpref = '_MB_'.mb_strtoupper($mydirname);
7 7
 
8
-if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref . '_LOADED')) {
9
-    define($constpref . '_LOADED', 1);
8
+if (defined('FOR_XOOPS_LANG_CHECKER') || !defined($constpref.'_LOADED')) {
9
+    define($constpref.'_LOADED', 1);
10 10
 
11 11
     // definitions for displaying blocks
12 12
     // Since altsys is a singleton moudle, this file has non-sense.
Please login to merge, or discard this patch.
xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php 1 patch
Spacing   +45 added lines, -45 removed lines patch added patch discarded remove patch
@@ -117,7 +117,7 @@  discard block
 block discarded – undo
117 117
 
118 118
             $moduleHandler = xoops_getHandler('module');
119 119
 
120
-         if (! empty($_GET['dirname'])) {
120
+         if (!empty($_GET['dirname'])) {
121 121
                 $dirname = preg_replace('/[^0-9a-zA-Z_-]/', '', \Xmf\Request::getString('dirname', '', 'GET'));
122 122
 
123 123
                 $target_module = $moduleHandler->getByDirname($dirname);
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
 
129 129
                 $this->target_mid = $target_module->getVar('mid');
130 130
 
131
-                $this->target_mname = $target_module->getVar('name') . '&nbsp;' . sprintf('(%2.2f)', $target_module->getVar('version') / 100.0);
131
+                $this->target_mname = $target_module->getVar('name').'&nbsp;'.sprintf('(%2.2f)', $target_module->getVar('version') / 100.0);
132 132
 
133 133
                 $this->target_dirname = $target_module->getVar('dirname');
134 134
 
@@ -138,9 +138,9 @@  discard block
 block discarded – undo
138 138
 
139 139
                 $breadcrumbsObj = AltsysBreadcrumbs::getInstance();
140 140
 
141
-                $breadcrumbsObj->appendPath(XOOPS_URL . '/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin', '_MI_ALTSYS_MENU_MYBLOCKSADMIN');
141
+                $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin', '_MI_ALTSYS_MENU_MYBLOCKSADMIN');
142 142
 
143
-                $breadcrumbsObj->appendPath(XOOPS_URL . '/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin&amp;dirname=' . $this->target_dirname, $this->target_mname);
143
+                $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin&amp;dirname='.$this->target_dirname, $this->target_mname);
144 144
             } else {
145 145
                 // custom blocks
146 146
 
@@ -154,28 +154,28 @@  discard block
 block discarded – undo
154 154
 
155 155
                 $breadcrumbsObj = AltsysBreadcrumbs::getInstance();
156 156
 
157
-                $breadcrumbsObj->appendPath(XOOPS_URL . '/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin', '_MI_ALTSYS_MENU_MYBLOCKSADMIN');
157
+                $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin', '_MI_ALTSYS_MENU_MYBLOCKSADMIN');
158 158
 
159
-                $breadcrumbsObj->appendPath(XOOPS_URL . '/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin&amp;dirname=' . $this->target_dirname, '_MI_ALTSYS_MENU_CUSTOMBLOCKS');
159
+                $breadcrumbsObj->appendPath(XOOPS_URL.'/modules/altsys/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin&amp;dirname='.$this->target_dirname, '_MI_ALTSYS_MENU_CUSTOMBLOCKS');
160 160
             }
161 161
         } else {
162 162
             // myblocksadmin as a library
163 163
 
164 164
             $this->target_mid = $xoopsModule->getVar('mid');
165 165
 
166
-            $this->target_mname = $xoopsModule->getVar('name') . '&nbsp;' . sprintf('(%2.2f)', $xoopsModule->getVar('version') / 100.0);
166
+            $this->target_mname = $xoopsModule->getVar('name').'&nbsp;'.sprintf('(%2.2f)', $xoopsModule->getVar('version') / 100.0);
167 167
 
168 168
             $this->target_dirname = $xoopsModule->getVar('dirname');
169 169
 
170
-            $mod_url = XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname');
170
+            $mod_url = XOOPS_URL.'/modules/'.$xoopsModule->getVar('dirname');
171 171
 
172 172
             $modinfo = $xoopsModule->getInfo();
173 173
 
174 174
             $breadcrumbsObj = AltsysBreadcrumbs::getInstance();
175 175
 
176
-            $breadcrumbsObj->appendPath($mod_url . '/' . @$modinfo['adminindex'], $this->target_mname);
176
+            $breadcrumbsObj->appendPath($mod_url.'/'.@$modinfo['adminindex'], $this->target_mname);
177 177
 
178
-            $breadcrumbsObj->appendPath($mod_url . '/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin', _MD_A_MYBLOCKSADMIN_BLOCKADMIN);
178
+            $breadcrumbsObj->appendPath($mod_url.'/admin/index.php?mode=admin&amp;lib=altsys&amp;page=myblocksadmin', _MD_A_MYBLOCKSADMIN_BLOCKADMIN);
179 179
         }
180 180
 
181 181
         // read xoops_version.php of the target
@@ -301,7 +301,7 @@  discard block
 block discarded – undo
301 301
         } else {
302 302
             // origined from the table of `block_module_link`
303 303
 
304
-            $result = $this->db->query('SELECT module_id FROM ' . $this->db->prefix('block_module_link') . " WHERE block_id='$bid'");
304
+            $result = $this->db->query('SELECT module_id FROM '.$this->db->prefix('block_module_link')." WHERE block_id='$bid'");
305 305
 
306 306
             $selected_mids = [];
307 307
 
@@ -370,7 +370,7 @@  discard block
 block discarded – undo
370 370
         } else {
371 371
             // origined from the table of `group_perm`
372 372
 
373
-            $result = $this->db->query('SELECT gperm_groupid FROM ' . $this->db->prefix('group_permission') . " WHERE gperm_itemid='$bid' AND gperm_name='block_read'");
373
+            $result = $this->db->query('SELECT gperm_groupid FROM '.$this->db->prefix('group_permission')." WHERE gperm_itemid='$bid' AND gperm_name='block_read'");
374 374
 
375 375
             $selected_gids = [];
376 376
 
@@ -473,31 +473,31 @@  discard block
 block discarded – undo
473 473
 
474 474
         return "
475 475
                 <div class='blockposition $scol0'>
476
-                    <input type='radio' name='sides[$bid]' value='" . XOOPS_SIDEBLOCK_LEFT . "' class='blockposition' $ssel0 onclick='document.getElementById(\"extra_side_$bid\").value=" . XOOPS_SIDEBLOCK_LEFT . ";' />
476
+                    <input type='radio' name='sides[$bid]' value='".XOOPS_SIDEBLOCK_LEFT."' class='blockposition' $ssel0 onclick='document.getElementById(\"extra_side_$bid\").value=".XOOPS_SIDEBLOCK_LEFT.";' />
477 477
                 </div>
478
-                <div style='float:" . _GLOBAL_LEFT . ";'>-</div>
478
+                <div style='float:" . _GLOBAL_LEFT.";'>-</div>
479 479
                 <div class='blockposition $scol2'>
480
-                    <input type='radio' name='sides[$bid]' value='" . XOOPS_CENTERBLOCK_LEFT . "' class='blockposition' $ssel2 onclick='document.getElementById(\"extra_side_$bid\").value=" . XOOPS_CENTERBLOCK_LEFT . ";' />
480
+                    <input type='radio' name='sides[$bid]' value='".XOOPS_CENTERBLOCK_LEFT."' class='blockposition' $ssel2 onclick='document.getElementById(\"extra_side_$bid\").value=".XOOPS_CENTERBLOCK_LEFT.";' />
481 481
                 </div>
482 482
                 <div class='blockposition $scol3'>
483
-                    <input type='radio' name='sides[$bid]' value='" . XOOPS_CENTERBLOCK_CENTER . "' class='blockposition' $ssel3 onclick='document.getElementById(\"extra_side_$bid\").value=" . XOOPS_CENTERBLOCK_CENTER . ";' />
483
+                    <input type='radio' name='sides[$bid]' value='".XOOPS_CENTERBLOCK_CENTER."' class='blockposition' $ssel3 onclick='document.getElementById(\"extra_side_$bid\").value=".XOOPS_CENTERBLOCK_CENTER.";' />
484 484
                 </div>
485 485
                 <div class='blockposition $scol4'>
486
-                    <input type='radio' name='sides[$bid]' value='" . XOOPS_CENTERBLOCK_RIGHT . "' class='blockposition' $ssel4 onclick='document.getElementById(\"extra_side_$bid\").value=" . XOOPS_CENTERBLOCK_RIGHT . ";' />
486
+                    <input type='radio' name='sides[$bid]' value='".XOOPS_CENTERBLOCK_RIGHT."' class='blockposition' $ssel4 onclick='document.getElementById(\"extra_side_$bid\").value=".XOOPS_CENTERBLOCK_RIGHT.";' />
487 487
                 </div>
488
-                <div style='float:" . _GLOBAL_LEFT . ";'>-</div>
488
+                <div style='float:" . _GLOBAL_LEFT.";'>-</div>
489 489
                 <div class='blockposition $scol1'>
490
-                    <input type='radio' name='sides[$bid]' value='" . XOOPS_SIDEBLOCK_RIGHT . "' class='blockposition' $ssel1 onclick='document.getElementById(\"extra_side_$bid\").value=" . XOOPS_SIDEBLOCK_RIGHT . ";' />
490
+                    <input type='radio' name='sides[$bid]' value='".XOOPS_SIDEBLOCK_RIGHT."' class='blockposition' $ssel1 onclick='document.getElementById(\"extra_side_$bid\").value=".XOOPS_SIDEBLOCK_RIGHT.";' />
491 491
                 </div>
492 492
                 <br />
493 493
                 <br />
494
-                <div style='float:" . _GLOBAL_LEFT . ";width:50px;' class='$stextbox'>
495
-                    <input type='text' name='extra_sides[$bid]' value='" . $value4extra_side . "' style='width:20px;' id='extra_side_$bid' />
494
+                <div style='float:" . _GLOBAL_LEFT.";width:50px;' class='$stextbox'>
495
+                    <input type='text' name='extra_sides[$bid]' value='".$value4extra_side."' style='width:20px;' id='extra_side_$bid' />
496 496
                 </div>
497 497
                 <div class='blockposition $scoln'>
498 498
                     <input type='radio' name='sides[$bid]' value='-1' class='blockposition' $sseln onclick='document.getElementById(\"extra_side_$bid\").value=-1;' />
499 499
                 </div>
500
-                <div style='float:" . _GLOBAL_LEFT . ";'>" . _NONE . '</div>
500
+                <div style='float:"._GLOBAL_LEFT.";'>"._NONE.'</div>
501 501
     ';
502 502
     }
503 503
 
@@ -509,7 +509,7 @@  discard block
 block discarded – undo
509 509
 
510 510
         // main query
511 511
 
512
-        $sql = 'SELECT * FROM ' . $this->db->prefix('newblocks') . " WHERE mid='$this->target_mid' ORDER BY visible DESC,side,weight";
512
+        $sql = 'SELECT * FROM '.$this->db->prefix('newblocks')." WHERE mid='$this->target_mid' ORDER BY visible DESC,side,weight";
513 513
 
514 514
         $result = $this->db->query($sql);
515 515
 
@@ -568,7 +568,7 @@  discard block
 block discarded – undo
568 568
 
569 569
         // display
570 570
 
571
-        require_once XOOPS_TRUST_PATH . '/libs/altsys/class/D3Tpl.class.php';
571
+        require_once XOOPS_TRUST_PATH.'/libs/altsys/class/D3Tpl.class.php';
572 572
 
573 573
         $tpl = new D3Tpl();
574 574
 
@@ -595,7 +595,7 @@  discard block
 block discarded – undo
595 595
             return [];
596 596
         }
597 597
 
598
-        include XOOPS_ROOT_PATH . '/modules/' . $this->target_dirname . '/xoops_version.php';
598
+        include XOOPS_ROOT_PATH.'/modules/'.$this->target_dirname.'/xoops_version.php';
599 599
 
600 600
         if (empty($modversion['blocks'])) {
601 601
             return [];
@@ -608,7 +608,7 @@  discard block
 block discarded – undo
608 608
     {
609 609
         // query for getting blocks
610 610
 
611
-        $sql = 'SELECT * FROM ' . $this->db->prefix('newblocks') . " WHERE mid='$this->target_mid' ORDER BY visible DESC,side,weight";
611
+        $sql = 'SELECT * FROM '.$this->db->prefix('newblocks')." WHERE mid='$this->target_mid' ORDER BY visible DESC,side,weight";
612 612
 
613 613
         $result = $this->db->query($sql);
614 614
 
@@ -645,9 +645,9 @@  discard block
 block discarded – undo
645 645
         // skip system (TODO)
646 646
 
647 647
         if ($this->target_mid > 1) {
648
-            $form->addAppendix('module_admin', $this->target_mid, $this->target_mname . ' ' . _MD_A_MYBLOCKSADMIN_PERM_MADMIN);
648
+            $form->addAppendix('module_admin', $this->target_mid, $this->target_mname.' '._MD_A_MYBLOCKSADMIN_PERM_MADMIN);
649 649
 
650
-            $form->addAppendix('module_read', $this->target_mid, $this->target_mname . ' ' . _MD_A_MYBLOCKSADMIN_PERM_MREAD);
650
+            $form->addAppendix('module_read', $this->target_mid, $this->target_mname.' '._MD_A_MYBLOCKSADMIN_PERM_MREAD);
651 651
         }
652 652
 
653 653
         foreach ($item_list as $item_id => $item_name) {
@@ -719,27 +719,27 @@  discard block
 block discarded – undo
719 719
         $msg = _MD_A_MYBLOCKSADMIN_DBUPDATED;
720 720
 
721 721
         if (false != $block->store()) {
722
-            include_once XOOPS_ROOT_PATH . '/class/template.php';
722
+            include_once XOOPS_ROOT_PATH.'/class/template.php';
723 723
 
724 724
             $xoopsTpl = new XoopsTpl();
725 725
 
726 726
             $xoopsTpl->xoops_setCaching(2);
727 727
 
728 728
             if ('' != $block->getVar('template')) {
729
-                if ($xoopsTpl->is_cached('db:' . $block->getVar('template'))) {
730
-                    if (!$xoopsTpl->clear_cache('db:' . $block->getVar('template'))) {
731
-                        $msg = 'Unable to clear cache for block ID' . $bid;
729
+                if ($xoopsTpl->is_cached('db:'.$block->getVar('template'))) {
730
+                    if (!$xoopsTpl->clear_cache('db:'.$block->getVar('template'))) {
731
+                        $msg = 'Unable to clear cache for block ID'.$bid;
732 732
                     }
733 733
                 }
734 734
             } else {
735
-                if ($xoopsTpl->is_cached('db:system_dummy.tpl', 'blk_' . $bid)) {
736
-                    if (!$xoopsTpl->clear_cache('db:system_dummy.tpl', 'blk_' . $bid)) {
737
-                        $msg = 'Unable to clear cache for block ID' . $bid;
735
+                if ($xoopsTpl->is_cached('db:system_dummy.tpl', 'blk_'.$bid)) {
736
+                    if (!$xoopsTpl->clear_cache('db:system_dummy.tpl', 'blk_'.$bid)) {
737
+                        $msg = 'Unable to clear cache for block ID'.$bid;
738 738
                     }
739 739
                 }
740 740
             }
741 741
         } else {
742
-            $msg = 'Failed update of block. ID:' . $bid;
742
+            $msg = 'Failed update of block. ID:'.$bid;
743 743
         }
744 744
 
745 745
         return $msg;
@@ -1078,7 +1078,7 @@  discard block
 block discarded – undo
1078 1078
         do {
1079 1079
             $func_num--;
1080 1080
 
1081
-            list($count) = $this->db->fetchRow($this->db->query('SELECT COUNT(*) FROM ' . $this->db->prefix('newblocks') . ' WHERE mid=' . (int)$mid . ' AND func_num=' . $func_num));
1081
+            list($count) = $this->db->fetchRow($this->db->query('SELECT COUNT(*) FROM '.$this->db->prefix('newblocks').' WHERE mid='.(int)$mid.' AND func_num='.$func_num));
1082 1082
         } while ($count > 0);
1083 1083
 
1084 1084
         return $func_num > 128 ? $func_num : 255;
@@ -1121,7 +1121,7 @@  discard block
 block discarded – undo
1121 1121
             // permission copy
1122 1122
 
1123 1123
             foreach ($GLOBALS['xoopsUser']->getGroups() as $gid) {
1124
-                $sql = 'INSERT INTO ' . $this->db->prefix('group_permission') . " (gperm_groupid, gperm_itemid, gperm_modid, gperm_name) VALUES ($gid, $bid, 1, 'block_read')";
1124
+                $sql = 'INSERT INTO '.$this->db->prefix('group_permission')." (gperm_groupid, gperm_itemid, gperm_modid, gperm_name) VALUES ($gid, $bid, 1, 'block_read')";
1125 1125
 
1126 1126
                 $this->db->query($sql);
1127 1127
             }
@@ -1259,7 +1259,7 @@  discard block
 block discarded – undo
1259 1259
 
1260 1260
         // display
1261 1261
 
1262
-        require_once XOOPS_TRUST_PATH . '/libs/altsys/class/D3Tpl.class.php';
1262
+        require_once XOOPS_TRUST_PATH.'/libs/altsys/class/D3Tpl.class.php';
1263 1263
 
1264 1264
         $tpl = new D3Tpl();
1265 1265
 
@@ -1268,7 +1268,7 @@  discard block
 block discarded – undo
1268 1268
         if (defined('XOOPS_CUBE_LEGACY')) {
1269 1269
             $tpl->assign('xoops_cube_legacy', true);
1270 1270
 
1271
-            include_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
1271
+            include_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
1272 1272
         } else {
1273 1273
             $tpl->assign('xoops_cube_legacy', false);
1274 1274
         }
@@ -1300,7 +1300,7 @@  discard block
 block discarded – undo
1300 1300
 
1301 1301
     public function checkFck()
1302 1302
     {
1303
-        return file_exists(XOOPS_ROOT_PATH . '/common/fckeditor/fckeditor.js');
1303
+        return file_exists(XOOPS_ROOT_PATH.'/common/fckeditor/fckeditor.js');
1304 1304
     }
1305 1305
 
1306 1306
     /**
@@ -1373,14 +1373,14 @@  discard block
 block discarded – undo
1373 1373
         // Ticket Check
1374 1374
 
1375 1375
         if (!$GLOBALS['xoopsSecurity']->check(true, 'myblocksadmin')) {
1376
-            redirect_header(XOOPS_URL . '/', 3, $GLOBALS['xoopsSecurity']->getErrors());
1376
+            redirect_header(XOOPS_URL.'/', 3, $GLOBALS['xoopsSecurity']->getErrors());
1377 1377
         }
1378 1378
 
1379 1379
         $msg = '';
1380 1380
 
1381 1381
         $bid = (int)(@$_GET['bid']);
1382 1382
 
1383
-        if (! empty($_POST['preview'])) {
1383
+        if (!empty($_POST['preview'])) {
1384 1384
             // preview
1385 1385
 
1386 1386
             $this->preview_request = $this->fetchRequest4Block($bid);
@@ -1407,12 +1407,12 @@  discard block
 block discarded – undo
1407 1407
         } elseif (!empty($_POST['submit'])) {
1408 1408
             // update module_admin,module_read,block_read
1409 1409
 
1410
-            include dirname(__DIR__) . '/include/mygroupperm.php';
1410
+            include dirname(__DIR__).'/include/mygroupperm.php';
1411 1411
 
1412 1412
             $msg = _MD_A_MYBLOCKSADMIN_PERMUPDATED;
1413 1413
         }
1414 1414
 
1415
-        redirect_header('?mode=admin&lib=altsys&page=myblocksadmin&dirname=' . $this->target_dirname, 1, $msg);
1415
+        redirect_header('?mode=admin&lib=altsys&page=myblocksadmin&dirname='.$this->target_dirname, 1, $msg);
1416 1416
 
1417 1417
         exit;
1418 1418
     }
Please login to merge, or discard this patch.