Completed
Push — master ( 8c936a...757841 )
by Michael
13s
created
admin/admin_header.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1,15 +1,15 @@
 block discarded – undo
1 1
 <?php
2
-include __DIR__ . '/../../../mainfile.php';
3
-include XOOPS_ROOT_PATH . '/include/cp_functions.php';
4
-include_once XOOPS_ROOT_PATH . '/kernel/module.php';
5
-include __DIR__ . '/../../../include/cp_header.php';
2
+include __DIR__.'/../../../mainfile.php';
3
+include XOOPS_ROOT_PATH.'/include/cp_functions.php';
4
+include_once XOOPS_ROOT_PATH.'/kernel/module.php';
5
+include __DIR__.'/../../../include/cp_header.php';
6 6
 if ($xoopsUser) {
7 7
     $xoopsModule = XoopsModule::getByDirname('myiframe');
8 8
     if (!$xoopsUser->isAdmin($xoopsModule->mid())) {
9
-        redirect_header(XOOPS_URL . '/', 3, _NOPERM);
9
+        redirect_header(XOOPS_URL.'/', 3, _NOPERM);
10 10
     }
11 11
 } else {
12
-    redirect_header(XOOPS_URL . '/', 3, _NOPERM);
12
+    redirect_header(XOOPS_URL.'/', 3, _NOPERM);
13 13
 }
14 14
 
15 15
 $myts = MyTextSanitizer::getInstance();
Please login to merge, or discard this patch.
index.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -6,29 +6,29 @@  discard block
 block discarded – undo
6 6
  * ****************************************************************************
7 7
  */
8 8
 
9
-require_once __DIR__ . '/../../mainfile.php';
10
-require_once XOOPS_ROOT_PATH . '/modules/myiframe/include/functions.php';
9
+require_once __DIR__.'/../../mainfile.php';
10
+require_once XOOPS_ROOT_PATH.'/modules/myiframe/include/functions.php';
11 11
 $GLOBALS['xoopsOption']['template_main'] = 'myiframe.tpl';
12
-require_once XOOPS_ROOT_PATH . '/header.php';
12
+require_once XOOPS_ROOT_PATH.'/header.php';
13 13
 
14 14
 $suplparam = '';
15 15
 if (isset($_GET)) {
16 16
     foreach ($_GET as $k => $v) {
17 17
         if (strtoupper(trim($k)) !== 'IFRAMEID') {
18
-            $suplparam .= $k . '=' . $v . '&';
18
+            $suplparam .= $k.'='.$v.'&';
19 19
         }
20 20
     }
21 21
 }
22 22
 
23 23
 if (strlen(xoops_trim($suplparam)) > 0) {
24
-    $suplparam = substr($suplparam, 0, strlen($suplparam) - 1);
24
+    $suplparam = substr($suplparam, 0, strlen($suplparam)-1);
25 25
 }
26 26
 
27 27
 /** @var \MyiframeMyiframeHandler $iframeHandler */
28 28
 $iframeHandler = xoops_getModuleHandler('myiframe', 'myiframe');
29 29
 
30 30
 if (isset($_GET['iframeid'])) {
31
-    $tblalign     = [
31
+    $tblalign = [
32 32
         'top',
33 33
         'middle',
34 34
         'bottom',
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
         'no',
41 41
         'auto'
42 42
     ];
43
-    $frameid      = (int)$_GET['iframeid'];
43
+    $frameid = (int) $_GET['iframeid'];
44 44
 
45 45
     $frame = $iframeHandler->get($frameid);
46 46
 
@@ -50,13 +50,13 @@  discard block
 block discarded – undo
50 50
         $xoopsTpl->assign('longdesc', $frame->getVar('frame_description'));
51 51
         $xoopsTpl->assign('width', $frame->getVar('frame_width'));
52 52
         $xoopsTpl->assign('height', $frame->getVar('frame_height'));
53
-        $xoopsTpl->assign('align', $tblalign[$frame->getVar('frame_align') - 1]);
53
+        $xoopsTpl->assign('align', $tblalign[$frame->getVar('frame_align')-1]);
54 54
         $xoopsTpl->assign('frameborder', $frame->getVar('frame_frameborder'));
55 55
         $xoopsTpl->assign('marginwidth', $frame->getVar('frame_marginwidth'));
56 56
         $xoopsTpl->assign('marginheight', $frame->getVar('frame_marginheight'));
57
-        $xoopsTpl->assign('scrolling', $tblscrolling[$frame->getVar('frame_scrolling') - 1]);
57
+        $xoopsTpl->assign('scrolling', $tblscrolling[$frame->getVar('frame_scrolling')-1]);
58 58
         if (xoops_trim($suplparam) !== '') {
59
-            $xoopsTpl->assign('url', $frame->getVar('frame_url') . '?' . $suplparam);
59
+            $xoopsTpl->assign('url', $frame->getVar('frame_url').'?'.$suplparam);
60 60
         } else {
61 61
             $xoopsTpl->assign('url', $frame->getVar('frame_url'));
62 62
         }
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
     }
69 69
 } else {
70 70
     if (myiframe_getmoduleoption('showlist')) {
71
-        $baseurl = XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname') . '/index.php';
71
+        $baseurl = XOOPS_URL.'/modules/'.$xoopsModule->getVar('dirname').'/index.php';
72 72
         $frarray = [];
73 73
         $critere = new Criteria('1', '1', '=');
74 74
         $critere->setSort('frame_description');
@@ -79,7 +79,7 @@  discard block
 block discarded – undo
79 79
                 if (xoops_trim($frame->getVar('frame_description')) === '') {
80 80
                     $liendesc = $frame->getVar('frame_url');
81 81
                 } else {
82
-                    $liendesc = "<a href='" . $baseurl . '?iframeid=' . $frame->getVar('frame_frameid') . "'>" . $frame->getVar('frame_description') . '</a>';
82
+                    $liendesc = "<a href='".$baseurl.'?iframeid='.$frame->getVar('frame_frameid')."'>".$frame->getVar('frame_description').'</a>';
83 83
                 }
84 84
                 $iframe['list'] = $liendesc;
85 85
                 $xoopsTpl->append('iframes', $iframe);
@@ -90,4 +90,4 @@  discard block
 block discarded – undo
90 90
         $xoopsTpl->assign('frame_error', _MYIFRAME_FRAME_ERROR);
91 91
     }
92 92
 }
93
-include XOOPS_ROOT_PATH . '/footer.php';
93
+include XOOPS_ROOT_PATH.'/footer.php';
Please login to merge, or discard this patch.
class/myiframe.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@  discard block
 block discarded – undo
10 10
     die('XOOPS root path not defined');
11 11
 }
12 12
 
13
-include_once XOOPS_ROOT_PATH . '/kernel/object.php';
13
+include_once XOOPS_ROOT_PATH.'/kernel/object.php';
14 14
 
15 15
 /**
16 16
  * Class Myiframe
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
             if (is_array($id)) {
45 45
                 $this->assignVars($id);
46 46
             } else {
47
-                $this->load((int)$id);
47
+                $this->load((int) $id);
48 48
             }
49 49
         } else {
50 50
             $this->setNew();
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
      */
57 57
     public function load($id)
58 58
     {
59
-        $sql   = 'SELECT * FROM ' . $this->db->prefix('myiframe') . ' WHERE frame_frameid=' . (int)$id;
59
+        $sql   = 'SELECT * FROM '.$this->db->prefix('myiframe').' WHERE frame_frameid='.(int) $id;
60 60
         $myrow = $this->db->fetchArray($this->db->query($sql));
61 61
         $this->assignVars($myrow);
62 62
         if (!$myrow) {
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
     public function get($id)
92 92
     {
93 93
         $ret = null;
94
-        $sql = 'SELECT * FROM ' . $this->db->prefix('myiframe') . '  WHERE frame_frameid=' . (int)$id;
94
+        $sql = 'SELECT * FROM '.$this->db->prefix('myiframe').'  WHERE frame_frameid='.(int) $id;
95 95
         if (!$result = $this->db->query($sql)) {
96 96
             return $ret;
97 97
         }
@@ -213,11 +213,11 @@  discard block
 block discarded – undo
213 213
     {
214 214
         $ret   = [];
215 215
         $limit = $start = 0;
216
-        $sql   = 'SELECT * FROM ' . $this->db->prefix('myiframe');
216
+        $sql   = 'SELECT * FROM '.$this->db->prefix('myiframe');
217 217
         if (isset($criteria) && is_subclass_of($criteria, 'criteriaelement')) {
218
-            $sql .= ' ' . $criteria->renderWhere();
218
+            $sql .= ' '.$criteria->renderWhere();
219 219
             if ($criteria->getSort() !== '') {
220
-                $sql .= ' ORDER BY ' . $criteria->getSort() . ' ' . $criteria->getOrder();
220
+                $sql .= ' ORDER BY '.$criteria->getSort().' '.$criteria->getOrder();
221 221
             }
222 222
             $limit = $criteria->getLimit();
223 223
             $start = $criteria->getStart();
@@ -243,9 +243,9 @@  discard block
 block discarded – undo
243 243
      */
244 244
     public function getCount(CriteriaCompo $criteria = null)
245 245
     {
246
-        $sql = 'SELECT COUNT(*) FROM ' . $this->db->prefix('myiframe');
246
+        $sql = 'SELECT COUNT(*) FROM '.$this->db->prefix('myiframe');
247 247
         if (isset($criteria) && is_subclass_of($criteria, 'criteriaelement')) {
248
-            $sql .= ' ' . $criteria->renderWhere();
248
+            $sql .= ' '.$criteria->renderWhere();
249 249
         }
250 250
         $result = $this->db->query($sql);
251 251
         if (!$result) {
@@ -262,9 +262,9 @@  discard block
 block discarded – undo
262 262
      */
263 263
     public function deleteAll(CriteriaCompo $criteria = null)
264 264
     {
265
-        $sql = 'DELETE FROM ' . $this->db->prefix('myiframe');
265
+        $sql = 'DELETE FROM '.$this->db->prefix('myiframe');
266 266
         if (isset($criteria) && is_subclass_of($criteria, 'criteriaelement')) {
267
-            $sql .= ' ' . $criteria->renderWhere();
267
+            $sql .= ' '.$criteria->renderWhere();
268 268
         }
269 269
         if (!$result = $this->db->query($sql)) {
270 270
             return false;
@@ -278,7 +278,7 @@  discard block
 block discarded – undo
278 278
      */
279 279
     public function updatehits($frame_id)
280 280
     {
281
-        $sql = sprintf('UPDATE "%s" SET frame_hits = frame_hits+1 WHERE frame_frameid="%u"', $this->db->prefix('myiframe'), (int)$frame_id);
281
+        $sql = sprintf('UPDATE "%s" SET frame_hits = frame_hits+1 WHERE frame_frameid="%u"', $this->db->prefix('myiframe'), (int) $frame_id);
282 282
         $this->db->queryF($sql);
283 283
     }
284 284
 }
Please login to merge, or discard this patch.
blocks/myiframe_iframe.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -6,7 +6,7 @@  discard block
 block discarded – undo
6 6
  * ****************************************************************************
7 7
  */
8 8
 
9
-include_once XOOPS_ROOT_PATH . '/modules/myiframe/include/functions.php';
9
+include_once XOOPS_ROOT_PATH.'/modules/myiframe/include/functions.php';
10 10
 
11 11
 /**
12 12
  * @param $options
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
         'left',
23 23
         'rigth'
24 24
     ];
25
-    $tblscrolling  = [
25
+    $tblscrolling = [
26 26
         'yes',
27 27
         'no',
28 28
         'auto'
@@ -35,11 +35,11 @@  discard block
 block discarded – undo
35 35
         $block['longdesc']     = $frame->getVar('frame_description');
36 36
         $block['width']        = $frame->getVar('frame_width');
37 37
         $block['height']       = $frame->getVar('frame_height');
38
-        $block['align']        = $tblalign[$frame->getVar('frame_align') - 1];
38
+        $block['align']        = $tblalign[$frame->getVar('frame_align')-1];
39 39
         $block['frameborder']  = $frame->getVar('frame_frameborder');
40 40
         $block['marginwidth']  = $frame->getVar('frame_marginwidth');
41 41
         $block['marginheight'] = $frame->getVar('frame_marginheight');
42
-        $block['scrolling']    = $tblscrolling[$frame->getVar('frame_scrolling') - 1];
42
+        $block['scrolling']    = $tblscrolling[$frame->getVar('frame_scrolling')-1];
43 43
         $block['url']          = $frame->getVar('frame_url');
44 44
     }
45 45
     return $block;
@@ -58,14 +58,14 @@  discard block
 block discarded – undo
58 58
     $critere->setSort('frame_description');
59 59
     $frarray = $iframeHandler->getObjects($critere);
60 60
 
61
-    $form = '' . _MB_MYIFRAME_IFRAME . "&nbsp;<select name='options[0]'>";
61
+    $form = ''._MB_MYIFRAME_IFRAME."&nbsp;<select name='options[0]'>";
62 62
     /** @var Myiframe $oneframe */
63 63
     foreach ($frarray as $oneframe) {
64
-        $form .= "<option value='" . $oneframe->getVar('frame_frameid') . "'";
64
+        $form .= "<option value='".$oneframe->getVar('frame_frameid')."'";
65 65
         if ($options[0] == $oneframe->getVar('frame_frameid')) {
66 66
             $form .= " selected='selected'";
67 67
         }
68
-        $form .= '>' . $oneframe->getVar('frame_description') . '</option>';
68
+        $form .= '>'.$oneframe->getVar('frame_description').'</option>';
69 69
     }
70 70
     $form .= "</select>\n";
71 71
     return $form;
Please login to merge, or discard this patch.
admin/menu.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -23,19 +23,19 @@
 block discarded – undo
23 23
     [
24 24
         'title' => _MI_MYIFRAME_NAME,
25 25
         'link'  => 'admin/index.php',
26
-        'icon'  => $pathIcon32 . '/home.png'
26
+        'icon'  => $pathIcon32.'/home.png'
27 27
     ],
28 28
 
29 29
     [
30 30
         'title' => _MI_MYIFRAME_ADMENU1,
31 31
         'link'  => 'admin/manage.php',
32
-        'icon'  => $pathIcon32 . '/manage.png'
32
+        'icon'  => $pathIcon32.'/manage.png'
33 33
     ],
34 34
 
35 35
     // Category
36 36
     [
37 37
         'title' => _MI_MYIFRAME_ADMENU2,
38 38
         'link'  => 'admin/about.php',
39
-        'icon'  => $pathIcon32 . '/about.png'
39
+        'icon'  => $pathIcon32.'/about.png'
40 40
     ],
41 41
 ];
Please login to merge, or discard this patch.
admin/index.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@  discard block
 block discarded – undo
17 17
  * @author       XOOPS Development Team
18 18
  */
19 19
 
20
-require_once __DIR__ . '/admin_header.php';
20
+require_once __DIR__.'/admin_header.php';
21 21
 // Display Admin header
22 22
 xoops_cp_header();
23 23
 
@@ -25,4 +25,4 @@  discard block
 block discarded – undo
25 25
 $adminObject->displayNavigation(basename(__FILE__));
26 26
 $adminObject->displayIndex();
27 27
 
28
-require_once __DIR__ . '/admin_footer.php';
28
+require_once __DIR__.'/admin_footer.php';
Please login to merge, or discard this patch.
admin/manage.php 1 patch
Spacing   +38 added lines, -38 removed lines patch added patch discarded remove patch
@@ -7,25 +7,25 @@  discard block
 block discarded – undo
7 7
  */
8 8
 
9 9
 //include __DIR__ . '/../../../include/cp_header.php';
10
-require_once __DIR__ . '/admin_header.php';
11
-include_once XOOPS_ROOT_PATH . '/modules/myiframe/include/functions.php';
10
+require_once __DIR__.'/admin_header.php';
11
+include_once XOOPS_ROOT_PATH.'/modules/myiframe/include/functions.php';
12 12
 
13 13
 // Verify if the table is up to date
14 14
 if (!myiframe_FieldExists('frame_frameid', $GLOBALS['xoopsDB']->prefix('myiframe'))) {
15
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . ' CHANGE `frameid` `frame_frameid` INT( 8 ) NOT NULL AUTO_INCREMENT');
16
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `created` `frame_created` INT( 10 ) UNSIGNED NOT NULL DEFAULT '0'");
17
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `uid` `frame_uid` MEDIUMINT( 8 ) UNSIGNED NOT NULL DEFAULT '0'");
18
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . ' CHANGE `longdesc` `frame_description` VARCHAR( 255 ) NOT NULL');
19
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . ' CHANGE `width` `frame_width` VARCHAR( 15 ) NOT NULL');
20
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . ' CHANGE `height` `frame_height` VARCHAR( 15 ) NOT NULL');
21
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `align` `frame_align` SMALLINT( 2 ) NOT NULL DEFAULT '0'");
22
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `frameborder` `frame_frameborder` SMALLINT( 3 ) NOT NULL DEFAULT '0'");
23
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `marginwidth` `frame_marginwidth` SMALLINT( 3 ) NOT NULL DEFAULT '0'");
24
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `marginheight` `frame_marginheight` SMALLINT( 3 ) NOT NULL DEFAULT '0'");
25
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `scrolling` `frame_scrolling` SMALLINT( 1 ) NOT NULL DEFAULT '0'");
26
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . " CHANGE `hits` `frame_hits` INT( 8 ) UNSIGNED NOT NULL DEFAULT '0'");
27
-    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE ' . $GLOBALS['xoopsDB']->prefix('myiframe') . ' CHANGE `url` `frame_url` VARCHAR( 255 ) NOT NULL');
28
-    header('Location : ' . XOOPS_URL . '/modules/system/admin.php?fct=modulesadmin&op=update&module=myiframe');
15
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe').' CHANGE `frameid` `frame_frameid` INT( 8 ) NOT NULL AUTO_INCREMENT');
16
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `created` `frame_created` INT( 10 ) UNSIGNED NOT NULL DEFAULT '0'");
17
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `uid` `frame_uid` MEDIUMINT( 8 ) UNSIGNED NOT NULL DEFAULT '0'");
18
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe').' CHANGE `longdesc` `frame_description` VARCHAR( 255 ) NOT NULL');
19
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe').' CHANGE `width` `frame_width` VARCHAR( 15 ) NOT NULL');
20
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe').' CHANGE `height` `frame_height` VARCHAR( 15 ) NOT NULL');
21
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `align` `frame_align` SMALLINT( 2 ) NOT NULL DEFAULT '0'");
22
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `frameborder` `frame_frameborder` SMALLINT( 3 ) NOT NULL DEFAULT '0'");
23
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `marginwidth` `frame_marginwidth` SMALLINT( 3 ) NOT NULL DEFAULT '0'");
24
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `marginheight` `frame_marginheight` SMALLINT( 3 ) NOT NULL DEFAULT '0'");
25
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `scrolling` `frame_scrolling` SMALLINT( 1 ) NOT NULL DEFAULT '0'");
26
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe')." CHANGE `hits` `frame_hits` INT( 8 ) UNSIGNED NOT NULL DEFAULT '0'");
27
+    $result = $GLOBALS['xoopsDB']->queryF('ALTER TABLE '.$GLOBALS['xoopsDB']->prefix('myiframe').' CHANGE `url` `frame_url` VARCHAR( 255 ) NOT NULL');
28
+    header('Location : '.XOOPS_URL.'/modules/system/admin.php?fct=modulesadmin&op=update&module=myiframe');
29 29
 }
30 30
 
31 31
 $module_id = $xoopsModule->getVar('mid');
@@ -50,10 +50,10 @@  discard block
 block discarded – undo
50 50
  */
51 51
 function addEditForm($frameid, $Action, $FormTitle, $longdesc, $width, $height, $align, $frameborder, $marginwidth, $marginheight, $scrolling, $url, $LabelSubmitButton)
52 52
 {
53
-    include_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
53
+    include_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
54 54
     global $xoopsModule;
55 55
 
56
-    $sform = new XoopsThemeForm($FormTitle, 'indexform', XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname') . '/admin/manage.php');
56
+    $sform = new XoopsThemeForm($FormTitle, 'indexform', XOOPS_URL.'/modules/'.$xoopsModule->getVar('dirname').'/admin/manage.php');
57 57
     $sform->addElement(new XoopsFormText(_AM_MYIFRAME_DESC, 'longdesc', 50, 255, $longdesc), false);
58 58
     $sform->addElement(new XoopsFormText(_AM_MYIFRAME_WIDTH, 'width', 10, 15, $width), false);
59 59
     $sform->addElement(new XoopsFormText(_AM_MYIFRAME_HEIGHT, 'height', 10, 15, $height), false);
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
     $button_tray->addElement($cancel_btn);
92 92
     $sform->addElement($button_tray);
93 93
     $sform->display();
94
-    include_once __DIR__ . '/admin_footer.php';
94
+    include_once __DIR__.'/admin_footer.php';
95 95
 }
96 96
 
97 97
 // ******************************************************************************************************************************************
@@ -113,10 +113,10 @@  discard block
 block discarded – undo
113 113
                 $adminObject->displayNavigation(basename(__FILE__));
114 114
                 echo "<table width='100%' border='0' cellspacing='1' class='outer'>\n";
115 115
                 echo '<tr><td class="odd">';
116
-                echo "<a href='manage.php'><h4>" . _AM_MYIFRAME_CONFIG . '</h4></a>';
116
+                echo "<a href='manage.php'><h4>"._AM_MYIFRAME_CONFIG.'</h4></a>';
117 117
                 echo _AM_MYIFRAME_ERROR_ADD_INDEX;
118 118
                 echo '</td></tr></table>';
119
-                include_once __DIR__ . '/admin_footer.php';
119
+                include_once __DIR__.'/admin_footer.php';
120 120
                 xoops_cp_footer();
121 121
                 exit();
122 122
             }
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
         $adminObject = \Xmf\Module\Admin::getInstance();
148 148
         $adminObject->displayNavigation(basename(__FILE__));
149 149
         if (isset($_GET['frameid'])) {
150
-            $frameid = (int)$_GET['frameid'];
150
+            $frameid = (int) $_GET['frameid'];
151 151
             $frame   = $iframeHandler->get($frameid);
152 152
             addEditForm(
153 153
                 $frameid,
@@ -170,10 +170,10 @@  discard block
 block discarded – undo
170 170
             $adminObject->displayNavigation(basename(__FILE__));
171 171
             echo "<table width='100%' border='0' cellspacing='1' class='outer'>\n";
172 172
             echo '<tr><td class="odd">';
173
-            echo "<a href='manage.php'><h4>" . _AM_MYIFRAME_CONFIG . '</h4></a>';
173
+            echo "<a href='manage.php'><h4>"._AM_MYIFRAME_CONFIG.'</h4></a>';
174 174
             echo _AM_MYIFRAME_ERROR_ADD_INDEX;
175 175
             echo "</td></tr></table>\n";
176
-            include_once __DIR__ . '/admin_footer.php';
176
+            include_once __DIR__.'/admin_footer.php';
177 177
             xoops_cp_footer();
178 178
             exit();
179 179
         }
@@ -184,18 +184,18 @@  discard block
 block discarded – undo
184 184
             xoops_cp_header();
185 185
             $adminObject = \Xmf\Module\Admin::getInstance();
186 186
             $adminObject->displayNavigation(basename(__FILE__));
187
-            echo '<h4>' . _AM_MYIFRAME_CONFIG . '</h4>';
187
+            echo '<h4>'._AM_MYIFRAME_CONFIG.'</h4>';
188 188
             xoops_confirm([
189 189
                               'op'      => 'delete',
190
-                              'frameid' => (int)$_GET['frameid'],
190
+                              'frameid' => (int) $_GET['frameid'],
191 191
                               'ok'      => 1
192 192
                           ], 'manage.php', _AM_MYIFRAME_RUSUREDEL);
193
-            include_once __DIR__ . '/admin_footer.php';
193
+            include_once __DIR__.'/admin_footer.php';
194 194
         } else {
195 195
             if (empty($_POST['frameid'])) {
196 196
                 redirect_header('manage.php', 2, _AM_MYIFRAME_ERROR_ADD_INDEX);
197 197
             }
198
-            $frameid = (int)$_POST['frameid'];
198
+            $frameid = (int) $_POST['frameid'];
199 199
             $critere = new Criteria('frame_frameid', $frameid, '=');
200 200
             $iframeHandler->deleteAll($critere);
201 201
             redirect_header('manage.php', 1, _AM_MYIFRAME_DBUPDATED);
@@ -210,10 +210,10 @@  discard block
 block discarded – undo
210 210
                 $adminObject->displayNavigation(basename(__FILE__));
211 211
                 echo "<table width='100%' border='0' cellspacing='1' class='outer'>\n";
212 212
                 echo '<tr><td class="odd">';
213
-                echo "<a href='manage.php'><h4>" . _AM_MYIFRAME_CONFIG . '</h4></a>';
213
+                echo "<a href='manage.php'><h4>"._AM_MYIFRAME_CONFIG.'</h4></a>';
214 214
                 echo _AM_MYIFRAME_ERROR_ADD_INDEX;
215 215
                 echo "</td></tr></table>\n";
216
-                include_once __DIR__ . '/admin_footer.php';
216
+                include_once __DIR__.'/admin_footer.php';
217 217
                 xoops_cp_footer();
218 218
                 $adminObject = \Xmf\Module\Admin::getInstance();
219 219
                 $adminObject->displayNavigation(basename(__FILE__));
@@ -251,23 +251,23 @@  discard block
 block discarded – undo
251 251
         xoops_cp_header();
252 252
         $adminObject = \Xmf\Module\Admin::getInstance();
253 253
         $adminObject->displayNavigation(basename(__FILE__));
254
-        echo '<h4>' . _AM_MYIFRAME_CONFIG . "</h4><br />\n";
254
+        echo '<h4>'._AM_MYIFRAME_CONFIG."</h4><br />\n";
255 255
         echo "<table width='100%' border='0' cellspacing='1' class='outer'>\n";
256
-        echo "<tr><th align='center'>" . _AM_MYIFRAME_ID . "</th><th align='center'>" . _AM_MYIFRAME_DESC . "</th><th align='center'>" . _AM_MYIFRAME_CREATED . "</th><th align='center'>" . _AM_MYIFRAME_HITS . "</th><th align='center'>" . _AM_MYIFRAME_ACTION . "</th></tr>\n";
256
+        echo "<tr><th align='center'>"._AM_MYIFRAME_ID."</th><th align='center'>"._AM_MYIFRAME_DESC."</th><th align='center'>"._AM_MYIFRAME_CREATED."</th><th align='center'>"._AM_MYIFRAME_HITS."</th><th align='center'>"._AM_MYIFRAME_ACTION."</th></tr>\n";
257 257
         $critere = new Criteria('1', '1', '=');
258 258
         $critere->setSort('frame_description');
259 259
         $frarray = $iframeHandler->getObjects($critere);
260 260
         $class   = 'even';
261
-        $baseurl = XOOPS_URL . '/modules/' . $xoopsModule->getVar('dirname') . '/admin/manage.php';
261
+        $baseurl = XOOPS_URL.'/modules/'.$xoopsModule->getVar('dirname').'/admin/manage.php';
262 262
         if (count($frarray) > 0) {
263 263
             /** @var Myiframe $frame */
264 264
             foreach ($frarray as $frame) {
265
-                $action_edit   = "<a href='" . $baseurl . '?op=edit&frameid=' . $frame->getVar('frame_frameid') . "'><img src='../assets/images/edit.png' alt='" . _AM_MYIFRAME_EDIT . "'></a>";
266
-                $action_delete = "<a href='" . $baseurl . '?op=delete&frameid=' . $frame->getVar('frame_frameid') . "'><img src='../assets/images/delete.png' alt='" . _AM_MYIFRAME_DELETE . "'></a>";
265
+                $action_edit   = "<a href='".$baseurl.'?op=edit&frameid='.$frame->getVar('frame_frameid')."'><img src='../assets/images/edit.png' alt='"._AM_MYIFRAME_EDIT."'></a>";
266
+                $action_delete = "<a href='".$baseurl.'?op=delete&frameid='.$frame->getVar('frame_frameid')."'><img src='../assets/images/delete.png' alt='"._AM_MYIFRAME_DELETE."'></a>";
267 267
                 if (xoops_trim($frame->getVar('frame_description')) === '') {
268 268
                     $liendesc = $frame->getVar('frame_url');
269 269
                 } else {
270
-                    $liendesc = "<a href='" . XOOPS_URL . '/modules/myiframe/index.php?iframeid=' . $frame->getVar('frame_frameid') . "'>" . $frame->getVar('frame_description') . '</a>';
270
+                    $liendesc = "<a href='".XOOPS_URL.'/modules/myiframe/index.php?iframeid='.$frame->getVar('frame_frameid')."'>".$frame->getVar('frame_description').'</a>';
271 271
                 }
272 272
                 echo "<tr class='"
273 273
                      . $class
@@ -287,9 +287,9 @@  discard block
 block discarded – undo
287 287
                 $class = ($class === 'even') ? 'odd' : 'even';
288 288
             }
289 289
         }
290
-        echo "<tr class='" . $class . "'><td colspan='5' align='center'><form name='faddframe' method='post' action='manage.php'><input type='hidden' name='op' value='addframe'><input type='submit' name='submit' value='" . _AM_MYIFRAME_ADD . "'></td></tr>";
290
+        echo "<tr class='".$class."'><td colspan='5' align='center'><form name='faddframe' method='post' action='manage.php'><input type='hidden' name='op' value='addframe'><input type='submit' name='submit' value='"._AM_MYIFRAME_ADD."'></td></tr>";
291 291
         echo '</table>';
292
-        include_once __DIR__ . '/admin_footer.php';
292
+        include_once __DIR__.'/admin_footer.php';
293 293
         break;
294 294
 }
295 295
 
Please login to merge, or discard this patch.
admin/admin_footer.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,6 +19,6 @@
 block discarded – undo
19 19
 
20 20
 $pathIcon32 = Xmf\Module\Admin::iconUrl('', 32);
21 21
 
22
-echo "<div class='adminfooter'>\n" . "  <div style='text-align: center;'>\n" . "    <a href='http://www.xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" . "  </div>\n" . '  ' . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" . '</div>';
22
+echo "<div class='adminfooter'>\n"."  <div style='text-align: center;'>\n"."    <a href='http://www.xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n"."  </div>\n".'  '._AM_MODULEADMIN_ADMIN_FOOTER."\n".'</div>';
23 23
 
24 24
 xoops_cp_footer();
Please login to merge, or discard this patch.
xoops_version.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -66,15 +66,15 @@
 block discarded – undo
66 66
 
67 67
 if (is_object($xoopsModule) && $xoopsModule->getVar('dirname') == $modversion['dirname'] && $xoopsModule->getVar('isactive')) {
68 68
     $i = 0;
69
-    include_once XOOPS_ROOT_PATH . '/modules/myiframe/include/functions.php';
69
+    include_once XOOPS_ROOT_PATH.'/modules/myiframe/include/functions.php';
70 70
     $myts = MyTextSanitizer::getInstance();
71 71
     if (myiframe_getmoduleoption('showinmenu')) {
72
-        $sql    = 'SELECT * FROM ' . $GLOBALS['xoopsDB']->prefix('myiframe') . ' ORDER BY frame_description';
72
+        $sql    = 'SELECT * FROM '.$GLOBALS['xoopsDB']->prefix('myiframe').' ORDER BY frame_description';
73 73
         $result = $GLOBALS['xoopsDB']->query($sql);
74 74
         while (false !== ($myrow = $GLOBALS['xoopsDB']->fetchArray($result))) {
75 75
             if (xoops_trim($myrow['frame_description']) !== '') {
76 76
                 $modversion['sub'][$i]['name'] = $myts->htmlSpecialChars($myrow['frame_description']);
77
-                $modversion['sub'][$i]['url']  = 'index.php?iframeid=' . (int)$myrow['frame_frameid'];
77
+                $modversion['sub'][$i]['url']  = 'index.php?iframeid='.(int) $myrow['frame_frameid'];
78 78
                 $i++;
79 79
             }
80 80
         }
Please login to merge, or discard this patch.