Completed
Pull Request — master (#144)
by Michael
04:31
created
class/Fieldnull.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -30,9 +30,9 @@  discard block
 block discarded – undo
30 30
 class Fieldnull extends \XoopsObject
31 31
 {
32 32
     /**
33
-    *  @public function constructor class
34
-    *  @param null
35
-    */
33
+     *  @public function constructor class
34
+     *  @param null
35
+     */
36 36
 
37 37
     public function __construct()
38 38
     {
@@ -42,8 +42,8 @@  discard block
 block discarded – undo
42 42
     }
43 43
 
44 44
     /**
45
-    *  @static function getInstance
46
-    *  @param null
45
+     *  @static function getInstance
46
+     *  @param null
47 47
      * @return Fieldnull
48 48
      */
49 49
     public static function getInstance()
Please login to merge, or discard this patch.
class/LogoGenerator.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -23,11 +23,11 @@  discard block
 block discarded – undo
23 23
  *
24 24
  * @version         $Id: LogoGenerator.php 12258 2014-01-02 09:33:29Z timgno $
25 25
  */
26
-include_once dirname(dirname(dirname(__DIR__))) . '/mainfile.php';
26
+include_once dirname(dirname(dirname(__DIR__))).'/mainfile.php';
27 27
 //include_once XOOPS_ROOT_PATH . '/modules/TDMCreate/include/common.php';
28 28
 
29 29
 if (function_exists($_GET['f'])) { // get function name and parameter  $_GET['f']($_GET["p"]);
30
-    include_once __DIR__ . '/LogoGenerator.php';
30
+    include_once __DIR__.'/LogoGenerator.php';
31 31
     $ret = LogoGenerator::createLogo($_GET['iconName'], $_GET['caption']);
32 32
     phpFunction($ret);
33 33
 } else {
@@ -66,15 +66,15 @@  discard block
 block discarded – undo
66 66
         }
67 67
 
68 68
         $dirname = 'tdmcreate';
69
-        $iconFileName = XOOPS_ROOT_PATH . '/Frameworks/moduleclasses/icons/32/' . basename($logoIcon);
69
+        $iconFileName = XOOPS_ROOT_PATH.'/Frameworks/moduleclasses/icons/32/'.basename($logoIcon);
70 70
 
71 71
         //$dirFonts = TDMC_PATH . "/assets/fonts";
72 72
         //$dirLogos = TDMC_PATH . "/assets/images/logos";
73
-        $dirFonts = XOOPS_ROOT_PATH . '/modules/' . $dirname . '/assets/fonts';
74
-        $dirLogos = XOOPS_ROOT_PATH . '/modules/' . $dirname . '/assets/images/logos';
73
+        $dirFonts = XOOPS_ROOT_PATH.'/modules/'.$dirname.'/assets/fonts';
74
+        $dirLogos = XOOPS_ROOT_PATH.'/modules/'.$dirname.'/assets/images/logos';
75 75
 
76
-        if (!file_exists($imageBase = $dirLogos . '/empty.png') ||
77
-            !file_exists($font = $dirFonts . '/VeraBd.ttf') ||
76
+        if (!file_exists($imageBase = $dirLogos.'/empty.png') ||
77
+            !file_exists($font = $dirFonts.'/VeraBd.ttf') ||
78 78
             !file_exists($iconFile = $iconFileName)) {
79 79
             return false;
80 80
         }
@@ -90,13 +90,13 @@  discard block
 block discarded – undo
90 90
         imagecopy($imageModule, $imageIcon, 29, 2, 0, 0, 32, 32);
91 91
 
92 92
         //$targetImage = TDMC_UPLOAD_IMGMOD_URL . "/" . $moduleName . "_logo.png";
93
-        $targetImage = '/uploads/' . $dirname . '/images/modules/' . $moduleName . '_logo.png';
93
+        $targetImage = '/uploads/'.$dirname.'/images/modules/'.$moduleName.'_logo.png';
94 94
 
95
-        imagepng($imageModule, XOOPS_ROOT_PATH . $targetImage);
95
+        imagepng($imageModule, XOOPS_ROOT_PATH.$targetImage);
96 96
 
97 97
         imagedestroy($imageModule);
98 98
         imagedestroy($imageIcon);
99 99
 
100
-        return XOOPS_URL . $targetImage;
100
+        return XOOPS_URL.$targetImage;
101 101
     }
102 102
 }
Please login to merge, or discard this patch.
class/FieldElementsHandler.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -31,7 +31,7 @@
 block discarded – undo
31 31
 class FieldElementsHandler extends \XoopsPersistableObjectHandler
32 32
 {
33 33
     /**
34
-    *  @public function constructor class
34
+     *  @public function constructor class
35 35
      * @param null|\XoopsDatabase|\XoopsMySQLDatabase $db
36 36
      */
37 37
     public function __construct(\XoopsDatabase $db)
Please login to merge, or discard this patch.
class/Building.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@  discard block
 block discarded – undo
70 70
         $form->addElement($mod_select, true);
71 71
 
72 72
         $form->addElement(new \XoopsFormHidden('op', 'build'));
73
-        $form->addElement(new \XoopsFormButton(_REQUIRED . ' <sup class="red bold">*</sup>', 'submit', _SUBMIT, 'submit'));
73
+        $form->addElement(new \XoopsFormButton(_REQUIRED.' <sup class="red bold">*</sup>', 'submit', _SUBMIT, 'submit'));
74 74
 
75 75
         return $form;
76 76
     }
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
     public function clearDir($dir, $pattern = '*')
83 83
     {
84 84
         // Find all files and folders matching pattern
85
-        $files = glob($dir . "/$pattern");
85
+        $files = glob($dir."/$pattern");
86 86
         // Interate thorugh the files and folders
87 87
         foreach ($files as $file) {
88 88
             // if it's a directory then re-call clearDir function to delete files inside this directory
@@ -109,12 +109,12 @@  discard block
 block discarded – undo
109 109
         }
110 110
         while (false !== ($file = readdir($dir))) {
111 111
             if (('.' !== $file) && ('..' !== $file)) {
112
-                if (is_dir($src . '/' . $file)) {
112
+                if (is_dir($src.'/'.$file)) {
113 113
                     // Copy the directory itself
114
-                    $this->copyDir($src . '/' . $file, $dst . '/' . $file);
114
+                    $this->copyDir($src.'/'.$file, $dst.'/'.$file);
115 115
                 } else {
116 116
                     // Make sure you copy the current script
117
-                    copy($src . '/' . $file, $dst . '/' . $file);
117
+                    copy($src.'/'.$file, $dst.'/'.$file);
118 118
                 }
119 119
             }
120 120
         }
Please login to merge, or discard this patch.
class/Tables.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -181,18 +181,18 @@  discard block
 block discarded – undo
181 181
         $tableImage = $getTableImage ?: 'blank.gif';
182 182
         $icons32Directory = '/Frameworks/moduleclasses/icons/32';
183 183
         $uploadsDirectory = '/uploads/tdmcreate/images/tables';
184
-        $iconsDirectory = is_dir(XOOPS_ROOT_PATH . $icons32Directory) ? $icons32Directory : $uploadsDirectory;
184
+        $iconsDirectory = is_dir(XOOPS_ROOT_PATH.$icons32Directory) ? $icons32Directory : $uploadsDirectory;
185 185
 
186 186
         $imgtray1 = new \XoopsFormElementTray(_AM_TDMCREATE_TABLE_IMAGE, '<br>');
187 187
         $imgpath1 = sprintf(_AM_TDMCREATE_FORMIMAGE_PATH, ".{$iconsDirectory}/");
188 188
         $imageSelect1 = new \XoopsFormSelect($imgpath1, 'table_image', $tableImage, 10);
189
-        $imageArray1 = \XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH . $iconsDirectory);
189
+        $imageArray1 = \XoopsLists::getImgListAsArray(XOOPS_ROOT_PATH.$iconsDirectory);
190 190
         foreach ($imageArray1 as $image1) {
191 191
             $imageSelect1->addOption($image1, $image1);
192 192
         }
193
-        $imageSelect1->setExtra("onchange='showImgSelected(\"image1\", \"table_image\", \"" . $iconsDirectory . '", "", "' . XOOPS_URL . "\")'");
193
+        $imageSelect1->setExtra("onchange='showImgSelected(\"image1\", \"table_image\", \"".$iconsDirectory.'", "", "'.XOOPS_URL."\")'");
194 194
         $imgtray1->addElement($imageSelect1, false);
195
-        $imgtray1->addElement(new \XoopsFormLabel('', "<br><img src='" . XOOPS_URL . '/' . $iconsDirectory . '/' . $tableImage . "' name='image1' id='image1' alt='' />"));
195
+        $imgtray1->addElement(new \XoopsFormLabel('', "<br><img src='".XOOPS_URL.'/'.$iconsDirectory.'/'.$tableImage."' name='image1' id='image1' alt='' />"));
196 196
         $fileseltray1 = new \XoopsFormElementTray('', '<br>');
197 197
         $fileseltray1->addElement(new \XoopsFormFile(_AM_TDMCREATE_FORMUPLOAD, 'attachedfile', $helper->getConfig('maxsize')));
198 198
         $fileseltray1->addElement(new \XoopsFormLabel(''));
@@ -216,7 +216,7 @@  discard block
 block discarded – undo
216 216
         $checkbox = new \XoopsFormCheckbox(' ', 'table_option', $this->getOptionsTables(), '<br>');
217 217
         $checkbox->setDescription(_AM_TDMCREATE_OPTIONS_DESC);
218 218
         foreach ($this->options as $option) {
219
-            $checkbox->addOption($option, self::getDefinedLanguage('_AM_TDMCREATE_TABLE_' . mb_strtoupper($option)));
219
+            $checkbox->addOption($option, self::getDefinedLanguage('_AM_TDMCREATE_TABLE_'.mb_strtoupper($option)));
220 220
         }
221 221
         $optionsTray->addElement($checkbox);
222 222
 
@@ -224,7 +224,7 @@  discard block
 block discarded – undo
224 224
 
225 225
         $form->addElement($optionsTray);
226 226
 
227
-        $buttonTray = new \XoopsFormElementTray(_REQUIRED . ' <sup class="red bold">*</sup>', '');
227
+        $buttonTray = new \XoopsFormElementTray(_REQUIRED.' <sup class="red bold">*</sup>', '');
228 228
         $buttonTray->addElement(new \XoopsFormHidden('op', 'save'));
229 229
         $buttonTray->addElement(new \XoopsFormHidden('table_id', ($isNew ? 0 : $this->getVar('table_id'))));
230 230
         $buttonTray->addElement(new \XoopsFormButton('', 'submit', _SUBMIT, 'submit'));
@@ -273,7 +273,7 @@  discard block
 block discarded – undo
273 273
     {
274 274
         $retTable = [];
275 275
         foreach ($this->options as $option) {
276
-            if (1 == $this->getVar('table_' . $option)) {
276
+            if (1 == $this->getVar('table_'.$option)) {
277 277
                 $retTable[] = $option;
278 278
             }
279 279
         }
Please login to merge, or discard this patch.
class/Fieldattributes.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
  * @version         $Id: 1.91 fieldattributes.php 13027 2015-02-14 12:18:10Z timgno $
25 25
  */
26 26
 
27
- /**
27
+    /**
28 28
 *  @Class Fieldattributes
29 29
 *  @extends \XoopsObject
30 30
 */
@@ -35,9 +35,9 @@  discard block
 block discarded – undo
35 35
 class Fieldattributes extends \XoopsObject
36 36
 {
37 37
     /**
38
-    *  @public function constructor class
39
-    *  @param null
40
-    */
38
+     *  @public function constructor class
39
+     *  @param null
40
+     */
41 41
 
42 42
     public function __construct()
43 43
     {
@@ -47,8 +47,8 @@  discard block
 block discarded – undo
47 47
     }
48 48
 
49 49
     /**
50
-    *  @static function getInstance
51
-    *  @param null
50
+     *  @static function getInstance
51
+     *  @param null
52 52
      * @return Fieldattributes
53 53
      */
54 54
     public static function getInstance()
Please login to merge, or discard this patch.
class/Fieldtype.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -31,9 +31,9 @@  discard block
 block discarded – undo
31 31
 class Fieldtype extends \XoopsObject
32 32
 {
33 33
     /**
34
-    *  @public function constructor class
35
-    *  @param null
36
-    */
34
+     *  @public function constructor class
35
+     *  @param null
36
+     */
37 37
 
38 38
     public function __construct()
39 39
     {
@@ -43,8 +43,8 @@  discard block
 block discarded – undo
43 43
     }
44 44
 
45 45
     /**
46
-    *  @static function getInstance
47
-    *  @param null
46
+     *  @static function getInstance
47
+     *  @param null
48 48
      * @return Fieldtype
49 49
      */
50 50
     public static function getInstance()
Please login to merge, or discard this patch.
class/Helper.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@
 block discarded – undo
72 72
     {
73 73
         $ret   = false;
74 74
 
75
-        $class = '\\XoopsModules\\' . ucfirst(mb_strtolower(basename(dirname(__DIR__)))) . '\\' . $name . 'Handler';
75
+        $class = '\\XoopsModules\\'.ucfirst(mb_strtolower(basename(dirname(__DIR__)))).'\\'.$name.'Handler';
76 76
         if (!class_exists($class)) {
77 77
             throw new \RuntimeException("Class '$class' not found");
78 78
         }
Please login to merge, or discard this patch.
class/AddFiles.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -46,9 +46,9 @@  discard block
 block discarded – undo
46 46
     private $settings;
47 47
 
48 48
     /**
49
-    *  @public function constructor class
50
-    *  @param null
51
-    */
49
+     *  @public function constructor class
50
+     *  @param null
51
+     */
52 52
 
53 53
     public function __construct()
54 54
     {
@@ -75,8 +75,8 @@  discard block
 block discarded – undo
75 75
     }
76 76
 
77 77
     /**
78
-    *  @static function getInstance
79
-    *  @param null
78
+     *  @static function getInstance
79
+     *  @param null
80 80
      * @return AddFiles
81 81
      */
82 82
     public static function getInstance()
@@ -90,8 +90,8 @@  discard block
 block discarded – undo
90 90
     }
91 91
 
92 92
     /**
93
-    *  @public function getFormMoreFiles
94
-    *  @param mixed $action
93
+     *  @public function getFormMoreFiles
94
+     *  @param mixed $action
95 95
      *
96 96
      * @return \XoopsThemeForm
97 97
      */
Please login to merge, or discard this patch.