Test Setup Failed
Branch master (f1f823)
by Goffy
04:19
created
footer.php 2 patches
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
  * @author         Goffy - XOOPS Development Team - Email:<[email protected]> - Website:<https://wedega.com>
21 21
  */
22 22
 if (\count($xoBreadcrumbs) > 1) {
23
-	$GLOBALS['xoopsTpl']->assign('xoBreadcrumbs', $xoBreadcrumbs);
23
+    $GLOBALS['xoopsTpl']->assign('xoBreadcrumbs', $xoBreadcrumbs);
24 24
 }
25 25
 $GLOBALS['xoopsTpl']->assign('adv', $helper->getConfig('advertise'));
26 26
 // 
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,4 +30,4 @@
 block discarded – undo
30 30
 $GLOBALS['xoopsTpl']->assign('admin', WGGITHUB_ADMIN);
31 31
 $GLOBALS['xoopsTpl']->assign('copyright', $copyright);
32 32
 // 
33
-include_once \XOOPS_ROOT_PATH . '/footer.php';
33
+include_once \XOOPS_ROOT_PATH.'/footer.php';
Please login to merge, or discard this patch.
repositories.php 2 patches
Indentation   +32 added lines, -32 removed lines patch added patch discarded remove patch
@@ -47,38 +47,38 @@
 block discarded – undo
47 47
 $GLOBALS['xoopsTpl']->assign('showItem', $repoId > 0);
48 48
 
49 49
 switch ($op) {
50
-	case 'show':
51
-	case 'list':
52
-	default:
53
-		$crRepositories = new \CriteriaCompo();
54
-		if ($repoId > 0) {
55
-			$crRepositories->add(new \Criteria('repo_id', $repoId));
56
-		}
57
-		$repositoriesCount = $repositoriesHandler->getCount($crRepositories);
58
-		$GLOBALS['xoopsTpl']->assign('repositoriesCount', $repositoriesCount);
59
-		$crRepositories->setStart($start);
60
-		$crRepositories->setLimit($limit);
61
-		$repositoriesAll = $repositoriesHandler->getAll($crRepositories);
62
-		if ($repositoriesCount > 0) {
63
-			$repositories = [];
64
-			// Get All Repositories
65
-			foreach (\array_keys($repositoriesAll) as $i) {
66
-				$repositories[$i] = $repositoriesAll[$i]->getValuesRepositories();
67
-				$keywords[$i] = $repositoriesAll[$i]->getVar('repo_name');
68
-			}
69
-			$GLOBALS['xoopsTpl']->assign('repositories', $repositories);
70
-			unset($repositories);
71
-			// Display Navigation
72
-			if ($repositoriesCount > $limit) {
73
-				include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
74
-				$pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit=' . $limit);
75
-				$GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4));
76
-			}
77
-			$GLOBALS['xoopsTpl']->assign('type', $helper->getConfig('table_type'));
78
-			$GLOBALS['xoopsTpl']->assign('divideby', $helper->getConfig('divideby'));
79
-			$GLOBALS['xoopsTpl']->assign('numb_col', $helper->getConfig('numb_col'));
80
-		}
81
-		break;
50
+    case 'show':
51
+    case 'list':
52
+    default:
53
+        $crRepositories = new \CriteriaCompo();
54
+        if ($repoId > 0) {
55
+            $crRepositories->add(new \Criteria('repo_id', $repoId));
56
+        }
57
+        $repositoriesCount = $repositoriesHandler->getCount($crRepositories);
58
+        $GLOBALS['xoopsTpl']->assign('repositoriesCount', $repositoriesCount);
59
+        $crRepositories->setStart($start);
60
+        $crRepositories->setLimit($limit);
61
+        $repositoriesAll = $repositoriesHandler->getAll($crRepositories);
62
+        if ($repositoriesCount > 0) {
63
+            $repositories = [];
64
+            // Get All Repositories
65
+            foreach (\array_keys($repositoriesAll) as $i) {
66
+                $repositories[$i] = $repositoriesAll[$i]->getValuesRepositories();
67
+                $keywords[$i] = $repositoriesAll[$i]->getVar('repo_name');
68
+            }
69
+            $GLOBALS['xoopsTpl']->assign('repositories', $repositories);
70
+            unset($repositories);
71
+            // Display Navigation
72
+            if ($repositoriesCount > $limit) {
73
+                include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
74
+                $pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit=' . $limit);
75
+                $GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4));
76
+            }
77
+            $GLOBALS['xoopsTpl']->assign('type', $helper->getConfig('table_type'));
78
+            $GLOBALS['xoopsTpl']->assign('divideby', $helper->getConfig('divideby'));
79
+            $GLOBALS['xoopsTpl']->assign('numb_col', $helper->getConfig('numb_col'));
80
+        }
81
+        break;
82 82
 }
83 83
 
84 84
 // Breadcrumbs
Please login to merge, or discard this patch.
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -25,9 +25,9 @@  discard block
 block discarded – undo
25 25
 use XoopsModules\Wggithub\Constants;
26 26
 use XoopsModules\Wggithub\Common;
27 27
 
28
-require __DIR__ . '/header.php';
28
+require __DIR__.'/header.php';
29 29
 $GLOBALS['xoopsOption']['template_main'] = 'wggithub_repositories.tpl';
30
-include_once XOOPS_ROOT_PATH . '/header.php';
30
+include_once XOOPS_ROOT_PATH.'/header.php';
31 31
 
32 32
 $op    = Request::getCmd('op', 'list');
33 33
 $start = Request::getInt('start', 0);
@@ -70,8 +70,8 @@  discard block
 block discarded – undo
70 70
 			unset($repositories);
71 71
 			// Display Navigation
72 72
 			if ($repositoriesCount > $limit) {
73
-				include_once XOOPS_ROOT_PATH . '/class/pagenav.php';
74
-				$pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit=' . $limit);
73
+				include_once XOOPS_ROOT_PATH.'/class/pagenav.php';
74
+				$pagenav = new \XoopsPageNav($repositoriesCount, $limit, $start, 'start', 'op=list&limit='.$limit);
75 75
 				$GLOBALS['xoopsTpl']->assign('pagenav', $pagenav->renderNav(4));
76 76
 			}
77 77
 			$GLOBALS['xoopsTpl']->assign('type', $helper->getConfig('table_type'));
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
 $xoBreadcrumbs[] = ['title' => _MA_WGGITHUB_REPOSITORIES];
86 86
 
87 87
 // Keywords
88
-wggithubMetaKeywords($helper->getConfig('keywords') . ', ' . \implode(',', $keywords));
88
+wggithubMetaKeywords($helper->getConfig('keywords').', '.\implode(',', $keywords));
89 89
 unset($keywords);
90 90
 
91 91
 // Description
@@ -93,4 +93,4 @@  discard block
 block discarded – undo
93 93
 $GLOBALS['xoopsTpl']->assign('xoops_mpageurl', WGGITHUB_URL.'/repositories.php');
94 94
 $GLOBALS['xoopsTpl']->assign('wggithub_upload_url', WGGITHUB_UPLOAD_URL);
95 95
 
96
-require __DIR__ . '/footer.php';
96
+require __DIR__.'/footer.php';
Please login to merge, or discard this patch.
class/Settings.php 2 patches
Indentation   +110 added lines, -110 removed lines patch added patch discarded remove patch
@@ -32,119 +32,119 @@
 block discarded – undo
32 32
  */
33 33
 class Settings extends \XoopsObject
34 34
 {
35
-	/**
36
-	 * Constructor
37
-	 *
38
-	 * @param null
39
-	 */
40
-	public function __construct()
41
-	{
42
-		$this->initVar('set_id', XOBJ_DTYPE_INT);
43
-		$this->initVar('set_username', XOBJ_DTYPE_TXTBOX);
44
-		$this->initVar('set_token', XOBJ_DTYPE_TXTBOX);
45
-		$this->initVar('set_options', XOBJ_DTYPE_TXTAREA);
46
-		$this->initVar('set_primary', XOBJ_DTYPE_INT);
47
-		$this->initVar('set_date', XOBJ_DTYPE_INT);
48
-		$this->initVar('set_submitter', XOBJ_DTYPE_INT);
49
-	}
35
+    /**
36
+     * Constructor
37
+     *
38
+     * @param null
39
+     */
40
+    public function __construct()
41
+    {
42
+        $this->initVar('set_id', XOBJ_DTYPE_INT);
43
+        $this->initVar('set_username', XOBJ_DTYPE_TXTBOX);
44
+        $this->initVar('set_token', XOBJ_DTYPE_TXTBOX);
45
+        $this->initVar('set_options', XOBJ_DTYPE_TXTAREA);
46
+        $this->initVar('set_primary', XOBJ_DTYPE_INT);
47
+        $this->initVar('set_date', XOBJ_DTYPE_INT);
48
+        $this->initVar('set_submitter', XOBJ_DTYPE_INT);
49
+    }
50 50
 
51
-	/**
52
-	 * @static function &getInstance
53
-	 *
54
-	 * @param null
55
-	 */
56
-	public static function getInstance()
57
-	{
58
-		static $instance = false;
59
-		if (!$instance) {
60
-			$instance = new self();
61
-		}
62
-	}
51
+    /**
52
+     * @static function &getInstance
53
+     *
54
+     * @param null
55
+     */
56
+    public static function getInstance()
57
+    {
58
+        static $instance = false;
59
+        if (!$instance) {
60
+            $instance = new self();
61
+        }
62
+    }
63 63
 
64
-	/**
65
-	 * The new inserted $Id
66
-	 * @return inserted id
67
-	 */
68
-	public function getNewInsertedIdSettings()
69
-	{
70
-		$newInsertedId = $GLOBALS['xoopsDB']->getInsertId();
71
-		return $newInsertedId;
72
-	}
64
+    /**
65
+     * The new inserted $Id
66
+     * @return inserted id
67
+     */
68
+    public function getNewInsertedIdSettings()
69
+    {
70
+        $newInsertedId = $GLOBALS['xoopsDB']->getInsertId();
71
+        return $newInsertedId;
72
+    }
73 73
 
74
-	/**
75
-	 * @public function getForm
76
-	 * @param bool $action
77
-	 * @return \XoopsThemeForm
78
-	 */
79
-	public function getFormSettings($action = false)
80
-	{
81
-		$helper = \XoopsModules\Wggithub\Helper::getInstance();
82
-		if (!$action) {
83
-			$action = $_SERVER['REQUEST_URI'];
84
-		}
85
-		$isAdmin = $GLOBALS['xoopsUser']->isAdmin($GLOBALS['xoopsModule']->mid());
86
-		// Title
87
-		$title = $this->isNew() ? \sprintf(_AM_WGGITHUB_SETTING_ADD) : \sprintf(_AM_WGGITHUB_SETTING_EDIT);
88
-		// Get Theme Form
89
-		\xoops_load('XoopsFormLoader');
90
-		$form = new \XoopsThemeForm($title, 'form', $action, 'post', true);
91
-		$form->setExtra('enctype="multipart/form-data"');
92
-		// Form Text setUsername
93
-		$form->addElement(new \XoopsFormText(_AM_WGGITHUB_SETTING_USERNAME, 'set_username', 50, 255, $this->getVar('set_username')), true);
94
-		// Form Text setToken
95
-		$form->addElement(new \XoopsFormText(_AM_WGGITHUB_SETTING_TOKEN, 'set_token', 50, 255, $this->getVar('set_token')), true);
96
-		// Form Editor TextArea setOptions
97
-		$form->addElement(new \XoopsFormTextArea(_AM_WGGITHUB_SETTING_OPTIONS, 'set_options', $this->getVar('set_options', 'e'), 4, 47));
98
-		// Form Radio Yes/No setPrimary
99
-		$setPrimary = $this->isNew() ?: $this->getVar('set_primary');
100
-		$form->addElement(new \XoopsFormRadioYN(_AM_WGGITHUB_SETTING_PRIMARY, 'set_primary', $setPrimary));
101
-		// Form Text Date Select setDate
102
-		$setDate = $this->isNew() ?: $this->getVar('set_date');
103
-		$form->addElement(new \XoopsFormTextDateSelect(_AM_WGGITHUB_SETTING_DATE, 'set_date', '', $setDate));
104
-		// Form Select User setSubmitter
105
-		$form->addElement(new \XoopsFormSelectUser(_AM_WGGITHUB_SETTING_SUBMITTER, 'set_submitter', false, $this->getVar('set_submitter')));
106
-		// To Save
107
-		$form->addElement(new \XoopsFormHidden('op', 'save'));
108
-		$form->addElement(new \XoopsFormButtonTray('', _SUBMIT, 'submit', '', false));
109
-		return $form;
110
-	}
74
+    /**
75
+     * @public function getForm
76
+     * @param bool $action
77
+     * @return \XoopsThemeForm
78
+     */
79
+    public function getFormSettings($action = false)
80
+    {
81
+        $helper = \XoopsModules\Wggithub\Helper::getInstance();
82
+        if (!$action) {
83
+            $action = $_SERVER['REQUEST_URI'];
84
+        }
85
+        $isAdmin = $GLOBALS['xoopsUser']->isAdmin($GLOBALS['xoopsModule']->mid());
86
+        // Title
87
+        $title = $this->isNew() ? \sprintf(_AM_WGGITHUB_SETTING_ADD) : \sprintf(_AM_WGGITHUB_SETTING_EDIT);
88
+        // Get Theme Form
89
+        \xoops_load('XoopsFormLoader');
90
+        $form = new \XoopsThemeForm($title, 'form', $action, 'post', true);
91
+        $form->setExtra('enctype="multipart/form-data"');
92
+        // Form Text setUsername
93
+        $form->addElement(new \XoopsFormText(_AM_WGGITHUB_SETTING_USERNAME, 'set_username', 50, 255, $this->getVar('set_username')), true);
94
+        // Form Text setToken
95
+        $form->addElement(new \XoopsFormText(_AM_WGGITHUB_SETTING_TOKEN, 'set_token', 50, 255, $this->getVar('set_token')), true);
96
+        // Form Editor TextArea setOptions
97
+        $form->addElement(new \XoopsFormTextArea(_AM_WGGITHUB_SETTING_OPTIONS, 'set_options', $this->getVar('set_options', 'e'), 4, 47));
98
+        // Form Radio Yes/No setPrimary
99
+        $setPrimary = $this->isNew() ?: $this->getVar('set_primary');
100
+        $form->addElement(new \XoopsFormRadioYN(_AM_WGGITHUB_SETTING_PRIMARY, 'set_primary', $setPrimary));
101
+        // Form Text Date Select setDate
102
+        $setDate = $this->isNew() ?: $this->getVar('set_date');
103
+        $form->addElement(new \XoopsFormTextDateSelect(_AM_WGGITHUB_SETTING_DATE, 'set_date', '', $setDate));
104
+        // Form Select User setSubmitter
105
+        $form->addElement(new \XoopsFormSelectUser(_AM_WGGITHUB_SETTING_SUBMITTER, 'set_submitter', false, $this->getVar('set_submitter')));
106
+        // To Save
107
+        $form->addElement(new \XoopsFormHidden('op', 'save'));
108
+        $form->addElement(new \XoopsFormButtonTray('', _SUBMIT, 'submit', '', false));
109
+        return $form;
110
+    }
111 111
 
112
-	/**
113
-	 * Get Values
114
-	 * @param null $keys
115
-	 * @param null $format
116
-	 * @param null $maxDepth
117
-	 * @return array
118
-	 */
119
-	public function getValuesSettings($keys = null, $format = null, $maxDepth = null)
120
-	{
121
-		$helper  = \XoopsModules\Wggithub\Helper::getInstance();
122
-		$utility = new \XoopsModules\Wggithub\Utility();
123
-		$ret = $this->getValues($keys, $format, $maxDepth);
124
-		$ret['id']            = $this->getVar('set_id');
125
-		$ret['username']      = $this->getVar('set_username');
126
-		$ret['token']         = $this->getVar('set_token');
127
-		$ret['options']       = \strip_tags($this->getVar('set_options', 'e'));
128
-		$editorMaxchar = $helper->getConfig('editor_maxchar');
129
-		$ret['options_short'] = $utility::truncateHtml($ret['options'], $editorMaxchar);
130
-		$ret['primary']       = (int)$this->getVar('set_primary') > 0 ? _YES : _NO;
131
-		$ret['date']          = \formatTimestamp($this->getVar('set_date'), 's');
132
-		$ret['submitter']     = \XoopsUser::getUnameFromId($this->getVar('set_submitter'));
133
-		return $ret;
134
-	}
112
+    /**
113
+     * Get Values
114
+     * @param null $keys
115
+     * @param null $format
116
+     * @param null $maxDepth
117
+     * @return array
118
+     */
119
+    public function getValuesSettings($keys = null, $format = null, $maxDepth = null)
120
+    {
121
+        $helper  = \XoopsModules\Wggithub\Helper::getInstance();
122
+        $utility = new \XoopsModules\Wggithub\Utility();
123
+        $ret = $this->getValues($keys, $format, $maxDepth);
124
+        $ret['id']            = $this->getVar('set_id');
125
+        $ret['username']      = $this->getVar('set_username');
126
+        $ret['token']         = $this->getVar('set_token');
127
+        $ret['options']       = \strip_tags($this->getVar('set_options', 'e'));
128
+        $editorMaxchar = $helper->getConfig('editor_maxchar');
129
+        $ret['options_short'] = $utility::truncateHtml($ret['options'], $editorMaxchar);
130
+        $ret['primary']       = (int)$this->getVar('set_primary') > 0 ? _YES : _NO;
131
+        $ret['date']          = \formatTimestamp($this->getVar('set_date'), 's');
132
+        $ret['submitter']     = \XoopsUser::getUnameFromId($this->getVar('set_submitter'));
133
+        return $ret;
134
+    }
135 135
 
136
-	/**
137
-	 * Returns an array representation of the object
138
-	 *
139
-	 * @return array
140
-	 */
141
-	public function toArraySettings()
142
-	{
143
-		$ret = [];
144
-		$vars = $this->getVars();
145
-		foreach (\array_keys($vars) as $var) {
146
-			$ret[$var] = $this->getVar('"{$var}"');
147
-		}
148
-		return $ret;
149
-	}
136
+    /**
137
+     * Returns an array representation of the object
138
+     *
139
+     * @return array
140
+     */
141
+    public function toArraySettings()
142
+    {
143
+        $ret = [];
144
+        $vars = $this->getVars();
145
+        foreach (\array_keys($vars) as $var) {
146
+            $ret[$var] = $this->getVar('"{$var}"');
147
+        }
148
+        return $ret;
149
+    }
150 150
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -127,7 +127,7 @@
 block discarded – undo
127 127
 		$ret['options']       = \strip_tags($this->getVar('set_options', 'e'));
128 128
 		$editorMaxchar = $helper->getConfig('editor_maxchar');
129 129
 		$ret['options_short'] = $utility::truncateHtml($ret['options'], $editorMaxchar);
130
-		$ret['primary']       = (int)$this->getVar('set_primary') > 0 ? _YES : _NO;
130
+		$ret['primary']       = (int) $this->getVar('set_primary') > 0 ? _YES : _NO;
131 131
 		$ret['date']          = \formatTimestamp($this->getVar('set_date'), 's');
132 132
 		$ret['submitter']     = \XoopsUser::getUnameFromId($this->getVar('set_submitter'));
133 133
 		return $ret;
Please login to merge, or discard this patch.
class/Common/ServerStats.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -36,19 +36,19 @@  discard block
 block discarded – undo
36 36
         //        $query = $GLOBALS['xoopsDB']->query($sql);
37 37
         //        list($meta) = $GLOBALS['xoopsDB']->fetchRow($query);
38 38
         $html .= '<fieldset>';
39
-        $html .= "<legend style='font-weight: bold; color: #900;'>" . \constant('CO_' . $moduleDirNameUpper . '_IMAGEINFO') . '</legend>';
39
+        $html .= "<legend style='font-weight: bold; color: #900;'>".\constant('CO_'.$moduleDirNameUpper.'_IMAGEINFO').'</legend>';
40 40
         $html .= "<div style='padding: 8px;'>";
41 41
         //        $html .= '<div>' . \constant('CO_' . $moduleDirNameUpper . '_METAVERSION') . $meta . "</div>";
42 42
         //        $html .= "<br>";
43 43
         //        $html .= "<br>";
44
-        $html .= '<div>' . \constant('CO_' . $moduleDirNameUpper . '_SPHPINI') . '</div>';
44
+        $html .= '<div>'.\constant('CO_'.$moduleDirNameUpper.'_SPHPINI').'</div>';
45 45
         $html .= '<ul>';
46 46
 
47
-        $gdlib = \function_exists('gd_info') ? '<span style="color: #008000;">' . \constant('CO_' . $moduleDirNameUpper . '_GDON') . '</span>' : '<span style="color: #ff0000;">' . \constant('CO_' . $moduleDirNameUpper . '_GDOFF') . '</span>';
48
-        $html  .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_GDLIBSTATUS') . $gdlib;
47
+        $gdlib = \function_exists('gd_info') ? '<span style="color: #008000;">'.\constant('CO_'.$moduleDirNameUpper.'_GDON').'</span>' : '<span style="color: #ff0000;">'.\constant('CO_'.$moduleDirNameUpper.'_GDOFF').'</span>';
48
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_GDLIBSTATUS').$gdlib;
49 49
         if (\function_exists('gd_info')) {
50 50
             if (true === ($gdlib = gd_info())) {
51
-                $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_GDLIBVERSION') . '<b>' . $gdlib['GD Version'] . '</b>';
51
+                $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_GDLIBVERSION').'<b>'.$gdlib['GD Version'].'</b>';
52 52
             }
53 53
         }
54 54
 
@@ -58,18 +58,18 @@  discard block
 block discarded – undo
58 58
         //    $registerglobals = (!\ini_get('register_globals')) ? "<span style=\"color: #008000;\">" . \constant('CO_' . $moduleDirNameUpper . '_OFF') . '</span>' : "<span style=\"color: #ff0000;\">" . \constant('CO_' . $moduleDirNameUpper . '_ON') . '</span>';
59 59
         //    $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_REGISTERGLOBALS . $registerglobals;
60 60
 
61
-        $downloads = \ini_get('file_uploads') ? '<span style="color: #008000;">' . \constant('CO_' . $moduleDirNameUpper . '_ON') . '</span>' : '<span style="color: #ff0000;">' . \constant('CO_' . $moduleDirNameUpper . '_OFF') . '</span>';
62
-        $html      .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_SERVERUPLOADSTATUS') . $downloads;
61
+        $downloads = \ini_get('file_uploads') ? '<span style="color: #008000;">'.\constant('CO_'.$moduleDirNameUpper.'_ON').'</span>' : '<span style="color: #ff0000;">'.\constant('CO_'.$moduleDirNameUpper.'_OFF').'</span>';
62
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_SERVERUPLOADSTATUS').$downloads;
63 63
 
64
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_MAXUPLOADSIZE') . ' <b><span style="color: #0000ff;">' . \ini_get('upload_max_filesize') . '</span></b>';
65
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_MAXPOSTSIZE') . ' <b><span style="color: #0000ff;">' . \ini_get('post_max_size') . '</span></b>';
66
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_MEMORYLIMIT') . ' <b><span style="color: #0000ff;">' . \ini_get('memory_limit') . '</span></b>';
64
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_MAXUPLOADSIZE').' <b><span style="color: #0000ff;">'.\ini_get('upload_max_filesize').'</span></b>';
65
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_MAXPOSTSIZE').' <b><span style="color: #0000ff;">'.\ini_get('post_max_size').'</span></b>';
66
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_MEMORYLIMIT').' <b><span style="color: #0000ff;">'.\ini_get('memory_limit').'</span></b>';
67 67
         $html .= '</ul>';
68 68
         $html .= '<ul>';
69
-        $html .= '<li>' . \constant('CO_' . $moduleDirNameUpper . '_SERVERPATH') . ' <b>' . XOOPS_ROOT_PATH . '</b>';
69
+        $html .= '<li>'.\constant('CO_'.$moduleDirNameUpper.'_SERVERPATH').' <b>'.XOOPS_ROOT_PATH.'</b>';
70 70
         $html .= '</ul>';
71 71
         $html .= '<br>';
72
-        $html .= \constant('CO_' . $moduleDirNameUpper . '_UPLOADPATHDSC') . '';
72
+        $html .= \constant('CO_'.$moduleDirNameUpper.'_UPLOADPATHDSC').'';
73 73
         $html .= '</div>';
74 74
         $html .= '</fieldset><br>';
75 75
 
Please login to merge, or discard this patch.
class/Common/Breadcrumb.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
         require $GLOBALS['xoops']->path('class/template.php');
74 74
         $breadcrumbTpl = new \XoopsTpl();
75 75
         $breadcrumbTpl->assign('breadcrumb', $this->bread);
76
-        $html = $breadcrumbTpl->fetch('db:' . $this->dirname . '_common_breadcrumb.tpl');
76
+        $html = $breadcrumbTpl->fetch('db:'.$this->dirname.'_common_breadcrumb.tpl');
77 77
         unset($breadcrumbTpl);
78 78
 
79 79
         return $html;
Please login to merge, or discard this patch.
class/Common/Resizer.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -65,8 +65,8 @@
 block discarded – undo
65 65
 
66 66
         if ($width > $this->maxWidth || $height > $this->maxHeight) {
67 67
             // recalc image size based on this->maxWidth/this->maxHeight
68
-			$new_width  = 0;
69
-			$new_height = 0;
68
+            $new_width  = 0;
69
+            $new_height = 0;
70 70
             if ($width > $height) {
71 71
                 if ($width < $this->maxWidth) {
72 72
                     $new_width = $width;
Please login to merge, or discard this patch.
Spacing   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -146,14 +146,14 @@  discard block
 block discarded – undo
146 146
         $max_height_resize = $this->maxHeight;
147 147
         if ($original_w > $original_h) {
148 148
             $max_height_ratio = $this->maxHeight / $original_h;
149
-            $max_width_resize = (int)\round($original_w * $max_height_ratio);
149
+            $max_width_resize = (int) \round($original_w * $max_height_ratio);
150 150
         } else {
151 151
             $max_width_ratio   = $this->maxWidth / $original_w;
152
-            $max_height_resize = (int)\round($original_h * $max_width_ratio);
152
+            $max_height_resize = (int) \round($original_h * $max_width_ratio);
153 153
         }
154 154
         if ($max_width_resize < $this->maxWidth) {
155 155
             $max_height_ratio  = $this->maxWidth / $max_width_resize;
156
-            $max_height_resize = (int)\round($this->maxHeight * $max_height_ratio);
156
+            $max_height_resize = (int) \round($this->maxHeight * $max_height_ratio);
157 157
             $max_width_resize  = $this->maxWidth;
158 158
         }
159 159
 
@@ -168,9 +168,9 @@  discard block
 block discarded – undo
168 168
         $max_width_offset  = 0;
169 169
         $max_height_offset = 0;
170 170
         if ($this->maxWidth < $max_width_resize) {
171
-            $max_width_offset = (int)\round(($max_width_resize - $this->maxWidth) / 2);
171
+            $max_width_offset = (int) \round(($max_width_resize - $this->maxWidth) / 2);
172 172
         } else {
173
-            $max_height_offset = (int)\round(($max_height_resize - $this->maxHeight) / 2);
173
+            $max_height_offset = (int) \round(($max_height_resize - $this->maxHeight) / 2);
174 174
         }
175 175
 
176 176
         if (!imagecopy($final, $thumb, 0, 0, $max_width_offset, $max_height_offset, $max_width_resize, $max_height_resize)) {
@@ -189,10 +189,10 @@  discard block
 block discarded – undo
189 189
         $dest = \imagecreatefromjpeg($this->endFile);
190 190
         $src  = \imagecreatefromjpeg($this->sourceFile);
191 191
         if (4 == $this->mergeType) {
192
-            $imgWidth  = (int)\round($this->maxWidth / 2 - 1);
193
-            $imgHeight = (int)\round($this->maxHeight / 2 - 1);
194
-            $posCol2   = (int)\round($this->maxWidth / 2 + 1);
195
-            $posRow2   = (int)\round($this->maxHeight / 2 + 1);
192
+            $imgWidth  = (int) \round($this->maxWidth / 2 - 1);
193
+            $imgHeight = (int) \round($this->maxHeight / 2 - 1);
194
+            $posCol2   = (int) \round($this->maxWidth / 2 + 1);
195
+            $posRow2   = (int) \round($this->maxHeight / 2 + 1);
196 196
             switch ($this->mergePos) {
197 197
                 case 1:
198 198
                     imagecopy($dest, $src, 0, 0, 0, 0, $imgWidth, $imgHeight); //top left
@@ -209,11 +209,11 @@  discard block
 block discarded – undo
209 209
             }
210 210
         }
211 211
         if (6 == $this->mergeType) {
212
-            $imgWidth  = (int)\round($this->maxWidth / 3 - 1);
213
-            $imgHeight = (int)\round($this->maxHeight / 2 - 1);
214
-            $posCol2   = (int)\round($this->maxWidth / 3 + 1);
215
-            $posCol3   = $posCol2 + (int)\round($this->maxWidth / 3 + 1);
216
-            $posRow2   = (int)\round($this->maxHeight / 2 + 1);
212
+            $imgWidth  = (int) \round($this->maxWidth / 3 - 1);
213
+            $imgHeight = (int) \round($this->maxHeight / 2 - 1);
214
+            $posCol2   = (int) \round($this->maxWidth / 3 + 1);
215
+            $posCol3   = $posCol2 + (int) \round($this->maxWidth / 3 + 1);
216
+            $posRow2   = (int) \round($this->maxHeight / 2 + 1);
217 217
 
218 218
             switch ($this->mergePos) {
219 219
                 case 1:
Please login to merge, or discard this patch.
class/Common/Migrate.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@
 block discarded – undo
88 88
                 $this->synchronizeTable($tableName);
89 89
                 $updateTable = $GLOBALS['xoopsDB']->prefix($tableName);
90 90
                 $joinTable   = $GLOBALS['xoopsDB']->prefix($srcTableName);
91
-                $sql         = "UPDATE `$updateTable` t1 INNER JOIN `$joinTable` t2 ON t1.post_id = t2.post_id \n" . "SET t1.dohtml = t2.dohtml,  t1.dosmiley = t2.dosmiley, t1.doxcode = t2.doxcode\n" . '  , t1.doimage = t2.doimage, t1.dobr = t2.dobr';
91
+                $sql         = "UPDATE `$updateTable` t1 INNER JOIN `$joinTable` t2 ON t1.post_id = t2.post_id \n"."SET t1.dohtml = t2.dohtml,  t1.dosmiley = t2.dosmiley, t1.doxcode = t2.doxcode\n".'  , t1.doimage = t2.doimage, t1.dobr = t2.dobr';
92 92
                 $this->tableHandler->addToQueue($sql);
93 93
             }
94 94
         }
Please login to merge, or discard this patch.
class/Common/Configurator.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -51,7 +51,7 @@
 block discarded – undo
51 51
         //        require \dirname(\dirname(__DIR__)) . '/config/config.php';
52 52
         //        $config = getConfig();
53 53
 
54
-        $config = include dirname(__DIR__, 2) . '/config/config.php';
54
+        $config = include dirname(__DIR__, 2).'/config/config.php';
55 55
 
56 56
         $this->name            = $config->name;
57 57
         $this->paths           = $config->paths;
Please login to merge, or discard this patch.
class/Common/ModuleFeedback.php 1 patch
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -67,29 +67,29 @@  discard block
 block discarded – undo
67 67
         $moduleDirNameUpper = \mb_strtoupper($moduleDirName);
68 68
         // Get Theme Form
69 69
         \xoops_load('XoopsFormLoader');
70
-        $form = new \XoopsThemeForm(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_FORM_TITLE'), 'formfeedback', 'feedback.php', 'post', true);
70
+        $form = new \XoopsThemeForm(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_FORM_TITLE'), 'formfeedback', 'feedback.php', 'post', true);
71 71
         $form->setExtra('enctype="multipart/form-data"');
72 72
 
73
-        $recipient = new \XoopsFormText(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_RECIPIENT'), 'recipient', 50, 255, $GLOBALS['xoopsModule']->getInfo('author_mail'));
73
+        $recipient = new \XoopsFormText(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_RECIPIENT'), 'recipient', 50, 255, $GLOBALS['xoopsModule']->getInfo('author_mail'));
74 74
         $recipient->setExtra('disabled="disabled"');
75 75
         $form->addElement($recipient);
76
-        $your_name = new \XoopsFormText(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_NAME'), 'your_name', 50, 255, $this->name);
77
-        $your_name->setExtra('placeholder="' . \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_NAME_PLACEHOLER') . '"');
76
+        $your_name = new \XoopsFormText(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_NAME'), 'your_name', 50, 255, $this->name);
77
+        $your_name->setExtra('placeholder="'.\constant('CO_'.$moduleDirNameUpper.'_'.'FB_NAME_PLACEHOLER').'"');
78 78
         $form->addElement($your_name);
79
-        $your_site = new \XoopsFormText(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_SITE'), 'your_site', 50, 255, $this->site);
80
-        $your_site->setExtra('placeholder="' . \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_SITE_PLACEHOLER') . '"');
79
+        $your_site = new \XoopsFormText(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_SITE'), 'your_site', 50, 255, $this->site);
80
+        $your_site->setExtra('placeholder="'.\constant('CO_'.$moduleDirNameUpper.'_'.'FB_SITE_PLACEHOLER').'"');
81 81
         $form->addElement($your_site);
82
-        $your_mail = new \XoopsFormText(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_MAIL'), 'your_mail', 50, 255, $this->email);
83
-        $your_mail->setExtra('placeholder="' . \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_MAIL_PLACEHOLER') . '"');
82
+        $your_mail = new \XoopsFormText(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_MAIL'), 'your_mail', 50, 255, $this->email);
83
+        $your_mail->setExtra('placeholder="'.\constant('CO_'.$moduleDirNameUpper.'_'.'FB_MAIL_PLACEHOLER').'"');
84 84
         $form->addElement($your_mail);
85 85
 
86
-        $fbtypeSelect = new \XoopsFormSelect(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE'), 'fb_type', $this->type);
86
+        $fbtypeSelect = new \XoopsFormSelect(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE'), 'fb_type', $this->type);
87 87
         $fbtypeSelect->addOption('', '');
88
-        $fbtypeSelect->addOption(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_SUGGESTION'), \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_SUGGESTION'));
89
-        $fbtypeSelect->addOption(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_BUGS'), \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_BUGS'));
90
-        $fbtypeSelect->addOption(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_TESTIMONIAL'), \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_TESTIMONIAL'));
91
-        $fbtypeSelect->addOption(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_FEATURES'), \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_FEATURES'));
92
-        $fbtypeSelect->addOption(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_OTHERS'), \constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_OTHERS'));
88
+        $fbtypeSelect->addOption(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_SUGGESTION'), \constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_SUGGESTION'));
89
+        $fbtypeSelect->addOption(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_BUGS'), \constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_BUGS'));
90
+        $fbtypeSelect->addOption(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_TESTIMONIAL'), \constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_TESTIMONIAL'));
91
+        $fbtypeSelect->addOption(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_FEATURES'), \constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_FEATURES'));
92
+        $fbtypeSelect->addOption(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_OTHERS'), \constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_OTHERS'));
93 93
         $form->addElement($fbtypeSelect, true);
94 94
 
95 95
         $editorConfigs           = [];
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
         $configHandler           = \xoops_getHandler('config');
105 105
         $config                  = &$configHandler->getConfigsByCat(0, $module->getVar('mid'));
106 106
         $editorConfigs['editor'] = $config['general_editor'];
107
-        $editor                  = new \XoopsFormEditor(\constant('CO_' . $moduleDirNameUpper . '_' . 'FB_TYPE_CONTENT'), 'fb_content', $editorConfigs);
107
+        $editor                  = new \XoopsFormEditor(\constant('CO_'.$moduleDirNameUpper.'_'.'FB_TYPE_CONTENT'), 'fb_content', $editorConfigs);
108 108
         $form->addElement($editor, true);
109 109
 
110 110
         $form->addElement(new \XoopsFormHidden('op', 'send'));
Please login to merge, or discard this patch.