Passed
Push — master ( 48d769...5ccf6e )
by Michael
07:14
created
class/pedigree.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,8 +38,8 @@
 block discarded – undo
38 38
     protected function __construct($debug)
39 39
     {
40 40
         $this->debug   = $debug;
41
-       $moduleDirName = basename(dirname(__DIR__));
42
-       parent::__construct($moduleDirName);
41
+        $moduleDirName = basename(dirname(__DIR__));
42
+        parent::__construct($moduleDirName);
43 43
     }
44 44
 
45 45
     /**
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
      */
38 38
     protected function __construct($debug)
39 39
     {
40
-        $this->debug   = $debug;
40
+        $this->debug = $debug;
41 41
        $moduleDirName = basename(dirname(__DIR__));
42 42
        parent::__construct($moduleDirName);
43 43
     }
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
 
89 89
             return null;
90 90
         }
91
-        $this->addLog("Getting config '{$name}' : " . print_r($this->config[$name], true));
91
+        $this->addLog("Getting config '{$name}' : ".print_r($this->config[$name], true));
92 92
 
93 93
         return $this->config[$name];
94 94
     }
@@ -105,7 +105,7 @@  discard block
 block discarded – undo
105 105
             $this->initConfig();
106 106
         }
107 107
         $this->config[$name] = $value;
108
-        $this->addLog("Setting config '{$name}' : " . $this->config[$name]);
108
+        $this->addLog("Setting config '{$name}' : ".$this->config[$name]);
109 109
 
110 110
         return $this->config[$name];
111 111
     }
@@ -117,12 +117,12 @@  discard block
 block discarded – undo
117 117
      */
118 118
     public function getHandler($name)
119 119
     {
120
-        if (!isset($this->handler[$name . 'Handler'])) {
120
+        if (!isset($this->handler[$name.'Handler'])) {
121 121
             $this->initHandler($name);
122 122
         }
123 123
         $this->addLog("Getting handler '{$name}'");
124 124
 
125
-        return $this->handler[$name . 'Handler'];
125
+        return $this->handler[$name.'Handler'];
126 126
     }
127 127
 
128 128
     public function initModule()
@@ -149,8 +149,8 @@  discard block
 block discarded – undo
149 149
      */
150 150
     public function initHandler($name)
151 151
     {
152
-        $this->addLog('INIT ' . $name . ' HANDLER');
153
-        $this->handler[$name . 'Handler'] = xoops_getModuleHandler($name, $this->dirname);
152
+        $this->addLog('INIT '.$name.' HANDLER');
153
+        $this->handler[$name.'Handler'] = xoops_getModuleHandler($name, $this->dirname);
154 154
     }
155 155
 
156 156
     /**
Please login to merge, or discard this patch.
class/SelectBox.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -45,11 +45,11 @@  discard block
 block discarded – undo
45 45
     {
46 46
         $this->fieldnumber  = $parentObject->getId();
47 47
         $this->fieldname    = $parentObject->fieldname;
48
-        $this->value        = $animalObject->{'user' . $this->fieldnumber};
48
+        $this->value        = $animalObject->{'user'.$this->fieldnumber};
49 49
         $this->defaultvalue = $parentObject->defaultvalue;
50 50
         $this->lookuptable  = $parentObject->lookuptable;
51 51
         if (0 == $this->lookuptable) {
52
-            echo "<span style='color: red;'><h3>A lookuptable must be specified for userfield" . $this->fieldnumber . '</h3></span>';
52
+            echo "<span style='color: red;'><h3>A lookuptable must be specified for userfield".$this->fieldnumber.'</h3></span>';
53 53
         }
54 54
     }
55 55
 
@@ -58,7 +58,7 @@  discard block
 block discarded – undo
58 58
      */
59 59
     public function editField()
60 60
     {
61
-        $select         = new \XoopsFormSelect('<b>' . $this->fieldname . '</b>', 'user' . $this->fieldnumber, $value = $this->value, $size = 1, $multiple = false);
61
+        $select         = new \XoopsFormSelect('<b>'.$this->fieldname.'</b>', 'user'.$this->fieldnumber, $value = $this->value, $size = 1, $multiple = false);
62 62
         $lookupcontents = parent::lookupField($this->fieldnumber);
63 63
         $lcCount        = count($lookupcontents);
64 64
         foreach ($lookupcontents as $i => $iValue) {
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
      */
76 76
     public function newField($name = '')
77 77
     {
78
-        $select         = new \XoopsFormSelect('<b>' . $this->fieldname . '</b>', $name . 'user' . $this->fieldnumber, $value = $this->defaultvalue, $size = 1, $multiple = false);
78
+        $select         = new \XoopsFormSelect('<b>'.$this->fieldname.'</b>', $name.'user'.$this->fieldnumber, $value = $this->defaultvalue, $size = 1, $multiple = false);
79 79
         $lookupcontents = parent::lookupField($this->fieldnumber);
80 80
         $lcCount        = count($lookupcontents);
81 81
         foreach ($lookupcontents as $i => $iValue) {
@@ -116,7 +116,7 @@  discard block
 block discarded – undo
116 116
             }
117 117
         }
118 118
 
119
-        return $this->fieldname . ' : ' . $choosenvalue;
119
+        return $this->fieldname.' : '.$choosenvalue;
120 120
     }
121 121
 
122 122
     /**
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
         $lookupcontents = parent::lookupField($this->fieldnumber);
146 146
         $lcCount        = count($lookupcontents);
147 147
         foreach ($lookupcontents as $i => $iValue) {
148
-            $select .= "<option value='" . $lookupcontents[$i]['id'] . "'>" . $lookupcontents[$i]['value'] . '</option>';
148
+            $select .= "<option value='".$lookupcontents[$i]['id']."'>".$lookupcontents[$i]['value'].'</option>';
149 149
         }
150 150
         $select .= '</select>';
151 151
 
Please login to merge, or discard this patch.
class/DateSelect.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -47,16 +47,16 @@  discard block
 block discarded – undo
47 47
         //@todo move language strings to language file
48 48
         $this->fieldnumber  = $parentObject->getId();
49 49
         $this->fieldname    = $parentObject->fieldname;
50
-        $this->value        = $animalObject->{'user' . $this->fieldnumber};
50
+        $this->value        = $animalObject->{'user'.$this->fieldnumber};
51 51
         $this->defaultvalue = $parentObject->defaultvalue;
52 52
         if ($parentObject->hasLookup()) {
53
-            xoops_error('No lookuptable may be specified for userfield ' . $this->fieldnumber, get_class($this));
53
+            xoops_error('No lookuptable may be specified for userfield '.$this->fieldnumber, get_class($this));
54 54
         }
55 55
         if ($parentObject->inAdvanced()) {
56
-            xoops_error('userfield ' . $this->fieldnumber . ' cannot be shown in advanced info', get_class($this));
56
+            xoops_error('userfield '.$this->fieldnumber.' cannot be shown in advanced info', get_class($this));
57 57
         }
58 58
         if ($parentObject->inPie()) {
59
-            xoops_error('A Pie-chart cannot be specified for userfield ' . $this->fieldnumber, get_class($this));
59
+            xoops_error('A Pie-chart cannot be specified for userfield '.$this->fieldnumber, get_class($this));
60 60
         }
61 61
     }
62 62
 
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
      */
66 66
     public function editField()
67 67
     {
68
-        $textarea = new \XoopsFormTextDateSelect('<b>' . $this->fieldname . '</b>', 'user' . $this->fieldnumber, $size = 15, $this->value);
68
+        $textarea = new \XoopsFormTextDateSelect('<b>'.$this->fieldname.'</b>', 'user'.$this->fieldnumber, $size = 15, $this->value);
69 69
 
70 70
         return $textarea;
71 71
     }
@@ -77,7 +77,7 @@  discard block
 block discarded – undo
77 77
      */
78 78
     public function newField($name = '')
79 79
     {
80
-        $textarea = new \XoopsFormTextDateSelect('<b>' . $this->fieldname . '</b>', $name . 'user' . $this->fieldnumber, $size = 15, $this->defaultvalue);
80
+        $textarea = new \XoopsFormTextDateSelect('<b>'.$this->fieldname.'</b>', $name.'user'.$this->fieldnumber, $size = 15, $this->defaultvalue);
81 81
 
82 82
         return $textarea;
83 83
     }
Please login to merge, or discard this patch.
class/Picture.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -34,23 +34,23 @@  discard block
 block discarded – undo
34 34
     {
35 35
         $this->fieldnumber  = $parentObject->getId();
36 36
         $this->fieldname    = $parentObject->fieldname;
37
-        $this->value        = $animalObject->{'user' . $this->fieldnumber};
37
+        $this->value        = $animalObject->{'user'.$this->fieldnumber};
38 38
         $this->defaultvalue = $parentObject->defaultvalue;
39 39
         $this->lookuptable  = $parentObject->hasLookup();
40 40
         if ($this->lookuptable) {
41
-            xoops_error('No lookuptable may be specified for userfield ' . $this->fieldnumber);
41
+            xoops_error('No lookuptable may be specified for userfield '.$this->fieldnumber);
42 42
         }
43 43
         if ($parentObject->inAdvanced()) {
44
-            xoops_error('userfield ' . $this->fieldnumber . ' cannot be shown in advanced info', get_class($this));
44
+            xoops_error('userfield '.$this->fieldnumber.' cannot be shown in advanced info', get_class($this));
45 45
         }
46 46
         if ($parentObject->inPie()) {
47
-            xoops_error('A Pie-chart cannot be specified for userfield ' . $this->fieldnumber, get_class($this));
47
+            xoops_error('A Pie-chart cannot be specified for userfield '.$this->fieldnumber, get_class($this));
48 48
         }
49 49
         if ('1' == $parentObject->viewinlist) {
50
-            xoops_error('userfield ' . $this->fieldnumber . ' cannot be included in listview', get_class($this));
50
+            xoops_error('userfield '.$this->fieldnumber.' cannot be included in listview', get_class($this));
51 51
         }
52 52
         if ('1' == $parentObject->hassearch) {
53
-            xoops_error('Search cannot be defined for userfield ' . $this->fieldnumber, get_class($this));
53
+            xoops_error('Search cannot be defined for userfield '.$this->fieldnumber, get_class($this));
54 54
         }
55 55
     }
56 56
 
@@ -59,7 +59,7 @@  discard block
 block discarded – undo
59 59
      */
60 60
     public function editField()
61 61
     {
62
-        $picturefield = new \XoopsFormFile($this->fieldname, 'user' . $this->fieldnumber, 1024000);
62
+        $picturefield = new \XoopsFormFile($this->fieldname, 'user'.$this->fieldnumber, 1024000);
63 63
         $picturefield->setExtra("size ='50'");
64 64
 
65 65
         return $picturefield;
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
      */
73 73
     public function newField($name = '')
74 74
     {
75
-        $picturefield = new \XoopsFormFile($this->fieldname, $name . 'user' . $this->fieldnumber, 1024000);
75
+        $picturefield = new \XoopsFormFile($this->fieldname, $name.'user'.$this->fieldnumber, 1024000);
76 76
         $picturefield->setExtra("size ='50'");
77 77
 
78 78
         return $picturefield;
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
      */
84 84
     public function viewField()
85 85
     {
86
-        $view = new \XoopsFormLabel($this->fieldname, '<img src="' . PEDIGREE_UPLOAD_URL . '/images/thumbnails/' . $this->value . '_400.jpeg">');
86
+        $view = new \XoopsFormLabel($this->fieldname, '<img src="'.PEDIGREE_UPLOAD_URL.'/images/thumbnails/'.$this->value.'_400.jpeg">');
87 87
 
88 88
         return $view;
89 89
     }
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
      */
94 94
     public function showField()
95 95
     {
96
-        return '<img src="' . PEDIGREE_UPLOAD_URL . '/images/thumbnails/' . $this->value . '_150.jpeg">';
96
+        return '<img src="'.PEDIGREE_UPLOAD_URL.'/images/thumbnails/'.$this->value.'_150.jpeg">';
97 97
     }
98 98
 
99 99
     /**
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
      */
102 102
     public function showValue()
103 103
     {
104
-        return '<img src="' . PEDIGREE_UPLOAD_URL . '/images/thumbnails/' . $this->value . '_400.jpeg">';
104
+        return '<img src="'.PEDIGREE_UPLOAD_URL.'/images/thumbnails/'.$this->value.'_400.jpeg">';
105 105
     }
106 106
 
107 107
     /**
Please login to merge, or discard this patch.
class/Utility.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -823,9 +823,9 @@
 block discarded – undo
823 823
     {
824 824
         $helper = Pedigree\Helper::getInstance();
825 825
 
826
-       $pedigree_isAdmin = $helper->isUserAdmin();
826
+        $pedigree_isAdmin = $helper->isUserAdmin();
827 827
 
828
-         return $pedigree_isAdmin;
828
+            return $pedigree_isAdmin;
829 829
     }
830 830
 
831 831
     public static function getXoopsCpHeader()
Please login to merge, or discard this patch.
Spacing   +41 added lines, -41 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
         //        $filteredFolder = XoopsFilterInput::clean($folder, 'PATH');
29 29
         if (!is_dir($folder)) {
30 30
             mkdir($folder);
31
-            file_put_contents($folder . '/index.html', '<script>history.go(-1);</script>');
31
+            file_put_contents($folder.'/index.html', '<script>history.go(-1);</script>');
32 32
         }
33 33
         //        chmod($filteredFolder, 0777);
34 34
     }
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
         $max_imgheight     = $GLOBALS['xoopsModuleConfig']['maximgheight']; //1000;
66 66
         $allowed_mimetypes = ['image/gif', 'image/jpeg', 'image/pjpeg', 'image/x-png', 'image/png'];
67 67
         //    $img_dir = XOOPS_ROOT_PATH . "/modules/" . $GLOBALS['xoopsModule']->dirname() . "/images" ;
68
-        $img_dir = $GLOBALS['xoopsModuleConfig']['uploaddir'] . '/images';
68
+        $img_dir = $GLOBALS['xoopsModuleConfig']['uploaddir'].'/images';
69 69
         require_once $GLOBALS['xoops']->path('class/uploader.php');
70 70
         $field = $_POST['xoops_upload_file'][$num];
71 71
         if (!empty($field) || '' != $field) {
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
     */
121 121
 
122 122
         // load the image
123
-        require_once $GLOBALS['xoops']->path('modules/' . $GLOBALS['xoopsModule']->dirname() . '/library/Zebra_Image.php');
123
+        require_once $GLOBALS['xoops']->path('modules/'.$GLOBALS['xoopsModule']->dirname().'/library/Zebra_Image.php');
124 124
         $thumbnail_widths = [150, 400];
125 125
 
126 126
         // indicate a target image
@@ -132,12 +132,12 @@  discard block
 block discarded – undo
132 132
         // create a new instance of the class
133 133
         $image = new \Zebra_Image();
134 134
         // indicate a source image (a GIF, PNG or JPEG file)
135
-        $image->source_path = PEDIGREE_UPLOAD_PATH . "/images/{$filename}";
135
+        $image->source_path = PEDIGREE_UPLOAD_PATH."/images/{$filename}";
136 136
 
137 137
         foreach ($thumbnail_widths as $thumbnail_width) {
138 138
 
139 139
             // generate & output thumbnail
140
-            $output_filename    = PEDIGREE_UPLOAD_PATH . '/images/thumbnails/' . basename($filename) . "_{$thumbnail_width}.{$config_output_format}";
140
+            $output_filename    = PEDIGREE_UPLOAD_PATH.'/images/thumbnails/'.basename($filename)."_{$thumbnail_width}.{$config_output_format}";
141 141
             $image->target_path = $output_filename;
142 142
             // since in this example we're going to have a jpeg file, let's set the output
143 143
             // image's quality
@@ -293,17 +293,17 @@  discard block
 block discarded – undo
293 293
                 $x = $columns[$i]['columnnumber'];
294 294
                 if (is_array($columns[$i]['lookupval'])) {
295 295
                     foreach ($columns[$i]['lookupval'] as $key => $keyvalue) {
296
-                        if ($keyvalue['id'] == $rowres['user' . $x]) {
296
+                        if ($keyvalue['id'] == $rowres['user'.$x]) {
297 297
                             $value = $keyvalue['value'];
298 298
                         }
299 299
                     }
300 300
                     //debug information
301 301
                     ///echo $columns[$i]['columnname']."is an array !";
302 302
                 } //format value - cant use object because of query count
303
-                elseif (0 === strncmp($rowres['user' . $x], 'http://', 7)) {
304
-                    $value = '<a href="' . $rowres['user' . $x] . '">' . $rowres['user' . $x] . '</a>';
303
+                elseif (0 === strncmp($rowres['user'.$x], 'http://', 7)) {
304
+                    $value = '<a href="'.$rowres['user'.$x].'">'.$rowres['user'.$x].'</a>';
305 305
                 } else {
306
-                    $value = $rowres['user' . $x];
306
+                    $value = $rowres['user'.$x];
307 307
                 }
308 308
                 $columnvalue[] = ['value' => $value];
309 309
             }
@@ -312,7 +312,7 @@  discard block
 block discarded – undo
312 312
                 'id'          => $rowres['d_id'],
313 313
                 'name'        => $name,
314 314
                 'gender'      => $gender,
315
-                'link'        => '<a href="dog.php?id=' . $rowres['d_id'] . '">' . $name . '</a>',
315
+                'link'        => '<a href="dog.php?id='.$rowres['d_id'].'">'.$name.'</a>',
316 316
                 'colour'      => '',
317 317
                 'number'      => '',
318 318
                 'usercolumns' => $columnvalue
@@ -333,9 +333,9 @@  discard block
 block discarded – undo
333 333
     {
334 334
         global $numofcolumns1, $nummatch1, $pages1, $columns1, $dogs1;
335 335
         if ('0' == $pa && '0' == $ma) {
336
-            $sqlquery = 'SELECT * FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_tree') . ' WHERE father = ' . $pa . ' AND mother = ' . $ma . ' AND id != ' . $oid . " AND father != '0' AND mother !='0' ORDER BY naam";
336
+            $sqlquery = 'SELECT * FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_tree').' WHERE father = '.$pa.' AND mother = '.$ma.' AND id != '.$oid." AND father != '0' AND mother !='0' ORDER BY naam";
337 337
         } else {
338
-            $sqlquery = 'SELECT * FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_tree') . ' WHERE father = ' . $pa . ' AND mother = ' . $ma . ' AND id != ' . $oid . ' ORDER BY naam';
338
+            $sqlquery = 'SELECT * FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_tree').' WHERE father = '.$pa.' AND mother = '.$ma.' AND id != '.$oid.' ORDER BY naam';
339 339
         }
340 340
         $queryresult = $GLOBALS['xoopsDB']->query($sqlquery);
341 341
         $nummatch1   = $GLOBALS['xoopsDB']->getRowsNum($queryresult);
@@ -382,17 +382,17 @@  discard block
 block discarded – undo
382 382
                 $x = $columns1[$i]['columnnumber'];
383 383
                 if (is_array($columns1[$i]['lookupval'])) {
384 384
                     foreach ($columns1[$i]['lookupval'] as $key => $keyvalue) {
385
-                        if ($keyvalue['id'] == $rowres['user' . $x]) {
385
+                        if ($keyvalue['id'] == $rowres['user'.$x]) {
386 386
                             $value = $keyvalue['value'];
387 387
                         }
388 388
                     }
389 389
                     //debug information
390 390
                     ///echo $columns[$i]['columnname']."is an array !";
391 391
                 } //format value - cant use object because of query count
392
-                elseif (0 === strncmp($rowres['user' . $x], 'http://', 7)) {
393
-                    $value = '<a href="' . $rowres['user' . $x] . '">' . $rowres['user' . $x] . '</a>';
392
+                elseif (0 === strncmp($rowres['user'.$x], 'http://', 7)) {
393
+                    $value = '<a href="'.$rowres['user'.$x].'">'.$rowres['user'.$x].'</a>';
394 394
                 } else {
395
-                    $value = $rowres['user' . $x];
395
+                    $value = $rowres['user'.$x];
396 396
                 }
397 397
                 $columnvalue1[] = ['value' => $value];
398 398
             }
@@ -400,7 +400,7 @@  discard block
 block discarded – undo
400 400
                 'id'          => $rowres['id'],
401 401
                 'name'        => $name,
402 402
                 'gender'      => $gender,
403
-                'link'        => '<a href="dog.php?id=' . $rowres['id'] . '">' . $name . '</a>',
403
+                'link'        => '<a href="dog.php?id='.$rowres['id'].'">'.$name.'</a>',
404 404
                 'colour'      => '',
405 405
                 'number'      => '',
406 406
                 'usercolumns' => $columnvalue1
@@ -421,9 +421,9 @@  discard block
 block discarded – undo
421 421
         $content = '';
422 422
 
423 423
         if (0 == $breeder) {
424
-            $sqlquery = 'SELECT id, naam, roft FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_tree') . " WHERE id_owner = '" . $oid . "' ORDER BY naam";
424
+            $sqlquery = 'SELECT id, naam, roft FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_tree')." WHERE id_owner = '".$oid."' ORDER BY naam";
425 425
         } else {
426
-            $sqlquery = 'SELECT id, naam, roft FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_tree') . " WHERE id_breeder = '" . $oid . "' ORDER BY naam";
426
+            $sqlquery = 'SELECT id, naam, roft FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_tree')." WHERE id_breeder = '".$oid."' ORDER BY naam";
427 427
         }
428 428
         $queryresult = $GLOBALS['xoopsDB']->query($sqlquery);
429 429
         while (false !== ($rowres = $GLOBALS['xoopsDB']->fetchArray($queryresult))) {
@@ -432,8 +432,8 @@  discard block
 block discarded – undo
432 432
             } else {
433 433
                 $gender = '<img src="assets/images/female.gif">';
434 434
             }
435
-            $link    = '<a href="dog.php?id=' . $rowres['id'] . '">' . stripslashes($rowres['naam']) . '</a>';
436
-            $content .= $gender . ' ' . $link . '<br>';
435
+            $link = '<a href="dog.php?id='.$rowres['id'].'">'.stripslashes($rowres['naam']).'</a>';
436
+            $content .= $gender.' '.$link.'<br>';
437 437
         }
438 438
 
439 439
         return $content;
@@ -447,7 +447,7 @@  discard block
 block discarded – undo
447 447
     public static function getName($oid)
448 448
     {
449 449
         $oid         = (int)$oid;
450
-        $sqlquery    = 'SELECT naam FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_tree') . " WHERE id = '{$oid}'";
450
+        $sqlquery    = 'SELECT naam FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_tree')." WHERE id = '{$oid}'";
451 451
         $queryresult = $GLOBALS['xoopsDB']->query($sqlquery);
452 452
         while (false !== ($rowres = $GLOBALS['xoopsDB']->fetchArray($queryresult))) {
453 453
             $an = stripslashes($rowres['naam']);
@@ -462,7 +462,7 @@  discard block
 block discarded – undo
462 462
      */
463 463
     public static function showParent($PA)
464 464
     {
465
-        $sqlquery    = 'SELECT naam FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_tree') . " WHERE id='" . $PA . "'";
465
+        $sqlquery    = 'SELECT naam FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_tree')." WHERE id='".$PA."'";
466 466
         $queryresult = $GLOBALS['xoopsDB']->query($sqlquery);
467 467
         while (false !== ($rowres = $GLOBALS['xoopsDB']->fetchArray($queryresult))) {
468 468
             $result = $rowres['naam'];
@@ -481,7 +481,7 @@  discard block
 block discarded – undo
481 481
      */
482 482
     public static function findId($naam_hond)
483 483
     {
484
-        $sqlquery    = 'SELECT id FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_tree') . " WHERE naam= '$naam_hond'";
484
+        $sqlquery    = 'SELECT id FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_tree')." WHERE naam= '$naam_hond'";
485 485
         $queryresult = $GLOBALS['xoopsDB']->query($sqlquery);
486 486
         while (false !== ($rowres = $GLOBALS['xoopsDB']->fetchArray($queryresult))) {
487 487
             $result = $rowres['id'];
@@ -534,8 +534,8 @@  discard block
 block discarded – undo
534 534
             $gender = '';
535 535
             if ((!empty($GLOBALS['xoopsUser']) && $GLOBALS['xoopsUser'] instanceof \XoopsUser)
536 536
                 && ($row['user'] == $GLOBALS['xoopsUser']->getVar('uid') || true === $modadmin)) {
537
-                $gender = "<a href='dog.php?id={$row['id']}'><img src='assets/images/edit.png' alt='" . _EDIT . "'></a>
538
-                     . <a href='delete.php?id={$row['id']}'><img src='assets/images/delete.png' alt='" . _DELETE . "'></a>";
537
+                $gender = "<a href='dog.php?id={$row['id']}'><img src='assets/images/edit.png' alt='"._EDIT."'></a>
538
+                     . <a href='delete.php?id={$row['id']}'><img src='assets/images/delete.png' alt='"._DELETE."'></a>";
539 539
             }
540 540
 
541 541
             $genImg = (0 == $row['roft']) ? 'male.gif' : 'female.gif';
@@ -546,7 +546,7 @@  discard block
 block discarded – undo
546 546
             } else {
547 547
                 $camera = '';
548 548
             }
549
-            $name = stripslashes($row['naam']) . $camera;
549
+            $name = stripslashes($row['naam']).$camera;
550 550
             unset($columnvalue);
551 551
 
552 552
             //fill array
@@ -555,22 +555,22 @@  discard block
 block discarded – undo
555 555
                 $lookuparray = $columns[$i]['lookuparray'];
556 556
                 if (is_array($lookuparray)) {
557 557
                     foreach ($lookuparray as $index => $indexValue) {
558
-                        if ($lookuparray[$index]['id'] == $row['user' . $x]) {
558
+                        if ($lookuparray[$index]['id'] == $row['user'.$x]) {
559 559
                             //echo "<h1>".$lookuparray[$index]['id']."</h1>";
560 560
                             $value = $lookuparray[$index]['value'];
561 561
                         }
562 562
                     }
563 563
                 } //format value - cant use object because of query count
564
-                elseif (0 === strncmp($row['user' . $x], 'http://', 7)) {
565
-                    $value = '<a href="' . $row['user' . $x] . '">' . $row['user' . $x] . '</a>';
564
+                elseif (0 === strncmp($row['user'.$x], 'http://', 7)) {
565
+                    $value = '<a href="'.$row['user'.$x].'">'.$row['user'.$x].'</a>';
566 566
                 } else {
567
-                    $value = $row['user' . $x];
567
+                    $value = $row['user'.$x];
568 568
                 }
569 569
                 $columnvalue[] = ['value' => $value];
570 570
                 unset($value);
571 571
             }
572 572
 
573
-            $linkto = '<a href="' . $link . $row[$element] . '">' . $name . '</a>';
573
+            $linkto = '<a href="'.$link.$row[$element].'">'.$name.'</a>';
574 574
             //create array
575 575
             $dogs[] = [
576 576
                 'id'          => $row['id'],
@@ -602,7 +602,7 @@  discard block
 block discarded – undo
602 602
         $cat_sql = '';
603 603
         if (is_array($cats)) {
604 604
             $cats    = array_map('intval', $cats); // make sure all cats are numbers
605
-            $cat_sql = '(' . implode(',', $cats) . ')';
605
+            $cat_sql = '('.implode(',', $cats).')';
606 606
         /*
607 607
                     $cat_sql = '(' . current($cats);
608 608
                     array_shift($cats);
@@ -612,7 +612,7 @@  discard block
 block discarded – undo
612 612
                     $cat_sql .= ')';
613 613
         */
614 614
         } else {
615
-            $cat_sql = '(' . (int)$cats . ')'; // not efficient but at least creates valid SQL statement
615
+            $cat_sql = '('.(int)$cats.')'; // not efficient but at least creates valid SQL statement
616 616
         }
617 617
 
618 618
         return $cat_sql;
@@ -751,7 +751,7 @@  discard block
 block discarded – undo
751 751
         //        xoops_load('XoopsLocal');
752 752
 
753 753
         //        $criteria = $myObject->getHandler($activeObject)->getActiveCriteria();
754
-        $criteria->setGroupby('UPPER(LEFT(' . $name . ',1))');
754
+        $criteria->setGroupby('UPPER(LEFT('.$name.',1))');
755 755
         $countsByLetters = $myObject->getHandler($activeObject)->getCounts($criteria);
756 756
         // Fill alphabet array
757 757
 
@@ -791,7 +791,7 @@  discard block
 block discarded – undo
791 791
                 $letter_array['count']  = $countsByLetters[$letter];
792 792
                 //            $letter_array['url']    = "" . XOOPS_URL . "/modules/" . $helper->getModule()->dirname() . "/viewcat.php?list={$letter}";
793 793
                 //                $letter_array['url'] = '' . XOOPS_URL . '/modules/' . $myObject->getModule()->dirname() . '/'.$file.'?f='.$name."&amp;l=1&amp;w={$letter}%25&amp;o=".$name;
794
-                $letter_array['url'] = '' . XOOPS_URL . '/modules/' . $myObject->getModule()->dirname() . '/' . $link . $letter . $link2;
794
+                $letter_array['url'] = ''.XOOPS_URL.'/modules/'.$myObject->getModule()->dirname().'/'.$link.$letter.$link2;
795 795
             } else {
796 796
                 $letter_array['letter'] = $letter;
797 797
                 $letter_array['count']  = 0;
@@ -810,7 +810,7 @@  discard block
 block discarded – undo
810 810
         $letterschoiceTpl          = new \XoopsTpl();
811 811
         $letterschoiceTpl->caching = false; // Disable cache
812 812
         $letterschoiceTpl->assign('alphabet', $alphabet_array);
813
-        $html = $letterschoiceTpl->fetch('db:' . $myObject->getModule()->dirname() . '_common_letterschoice.tpl');
813
+        $html = $letterschoiceTpl->fetch('db:'.$myObject->getModule()->dirname().'_common_letterschoice.tpl');
814 814
         unset($letterschoiceTpl);
815 815
 
816 816
         return $html;
@@ -847,7 +847,7 @@  discard block
 block discarded – undo
847 847
         if (!$withLink) {
848 848
             return $pedigreeModuleName;
849 849
         } else {
850
-            return '<a href="' . PEDIGREE_URL . '/">{$pedigreeModuleName}</a>';
850
+            return '<a href="'.PEDIGREE_URL.'/">{$pedigreeModuleName}</a>';
851 851
         }
852 852
     }
853 853
 
@@ -868,7 +868,7 @@  discard block
 block discarded – undo
868 868
         $GLOBALS['xoopsDB'] = \XoopsDatabaseFactory::getDatabaseConnection();
869 869
         $realName           = $GLOBALS['xoopsDB']->prefix($table);
870 870
 
871
-        $sql = 'SHOW TABLES FROM ' . XOOPS_DB_NAME;
871
+        $sql = 'SHOW TABLES FROM '.XOOPS_DB_NAME;
872 872
         $ret = $GLOBALS['xoopsDB']->queryF($sql);
873 873
 
874 874
         while (false !== (list($m_table) = $GLOBALS['xoopsDB']->fetchRow($ret))) {
@@ -972,10 +972,10 @@  discard block
 block discarded – undo
972 972
         $queryString = $_SERVER['QUERY_STRING'];
973 973
 
974 974
         if ('' != $queryString) {
975
-            $queryString = '?' . $queryString;
975
+            $queryString = '?'.$queryString;
976 976
         }
977 977
 
978
-        $currentURL = $http . $httpHost . $phpSelf . $queryString;
978
+        $currentURL = $http.$httpHost.$phpSelf.$queryString;
979 979
 
980 980
         $urls                = [];
981 981
         $urls['http']        = $http;
Please login to merge, or discard this patch.
class/HtmlInputAbstract.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@
 block discarded – undo
85 85
     {
86 86
         $ret = [];
87 87
         global $xoopsDB;
88
-        $SQL    = 'SELECT * FROM ' . $GLOBALS['xoopsDB']->prefix('pedigree_lookup' . $fieldnumber) . " ORDER BY 'order'";
88
+        $SQL    = 'SELECT * FROM '.$GLOBALS['xoopsDB']->prefix('pedigree_lookup'.$fieldnumber)." ORDER BY 'order'";
89 89
         $result = $GLOBALS['xoopsDB']->query($SQL);
90 90
         while (false !== ($row = $GLOBALS['xoopsDB']->fetchArray($result))) {
91 91
             $ret[] = ['id' => $row['id'], 'value' => $row['value']];
Please login to merge, or discard this patch.
class/TextBox.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -44,17 +44,17 @@  discard block
 block discarded – undo
44 44
     {
45 45
         $this->fieldnumber  = $parentObject->getId();
46 46
         $this->fieldname    = $parentObject->fieldname;
47
-        $this->value        = $animalObject->{'user' . $this->fieldnumber};
47
+        $this->value        = $animalObject->{'user'.$this->fieldnumber};
48 48
         $this->defaultvalue = $parentObject->defaultvalue;
49 49
         $this->lookuptable  = $parentObject->lookuptable;
50 50
         if ('1' == $this->lookuptable) {
51
-            xoops_error('No lookuptable may be specified for userfield ' . $this->fieldnumber, get_class($this));
51
+            xoops_error('No lookuptable may be specified for userfield '.$this->fieldnumber, get_class($this));
52 52
         }
53 53
         if ('1' == $parentObject->viewinadvanced) {
54
-            xoops_error('userfield ' . $this->fieldnumber . ' cannot be shown in advanced info', get_class($this));
54
+            xoops_error('userfield '.$this->fieldnumber.' cannot be shown in advanced info', get_class($this));
55 55
         }
56 56
         if ('1' == $parentObject->viewinpie) {
57
-            xoops_error('A Pie-chart cannot be specified for userfield ' . $this->fieldnumber, get_class($this));
57
+            xoops_error('A Pie-chart cannot be specified for userfield '.$this->fieldnumber, get_class($this));
58 58
         }
59 59
     }
60 60
 
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
      */
65 65
     public function editField()
66 66
     {
67
-        $textbox = new \XoopsFormText('<b>' . $this->fieldname . '</b>', 'user' . $this->fieldnumber, $size = 50, $maxsize = 50, $value = $this->value);
67
+        $textbox = new \XoopsFormText('<b>'.$this->fieldname.'</b>', 'user'.$this->fieldnumber, $size = 50, $maxsize = 50, $value = $this->value);
68 68
 
69 69
         return $textbox;
70 70
     }
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
      */
77 77
     public function newField($name = '')
78 78
     {
79
-        $textbox = new \XoopsFormText('<b>' . $this->fieldname . '</b>', $name . 'user' . $this->fieldnumber, $size = 50, $maxsize = 50, $value = $this->defaultvalue);
79
+        $textbox = new \XoopsFormText('<b>'.$this->fieldname.'</b>', $name.'user'.$this->fieldnumber, $size = 50, $maxsize = 50, $value = $this->defaultvalue);
80 80
 
81 81
         return $textbox;
82 82
     }
Please login to merge, or discard this patch.
class/Fields.php 2 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -96,9 +96,9 @@
 block discarded – undo
96 96
         $currentType = $this->getVar('litter') ? 'litter' : 'generallitter';
97 97
         $litterRadio = new \XoopsFormRadio(_AM_PEDIGREE_PEDIGREE_CONFIG_LITTER_TYPE, 'litterType', $currentType);
98 98
         $litterRadio->addOptionArray([
99
-                                         'litter'        => _AM_PEDIGREE_PEDIGREE_CONFIG_LITTER,
100
-                                         'generallitter' => _AM_PEDIGREE_PEDIGREE_CONFIG_GENERALLITTER
101
-                                     ]);
99
+                                            'litter'        => _AM_PEDIGREE_PEDIGREE_CONFIG_LITTER,
100
+                                            'generallitter' => _AM_PEDIGREE_PEDIGREE_CONFIG_GENERALLITTER
101
+                                        ]);
102 102
         $form->addElement($litterRadio, false);
103 103
         //        $form->addElement(new \XoopsFormRadioYN(_AM_PEDIGREE_PEDIGREE_CONFIG_LITTER, "Litter", $this->getVar("Litter")), false);
104 104
         //        $form->addElement(new \XoopsFormRadioYN(_AM_PEDIGREE_PEDIGREE_CONFIG_GENERALLITTER, "Generallitter", $this->getVar("Generallitter")), false);
Please login to merge, or discard this patch.
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -164,7 +164,7 @@  discard block
 block discarded – undo
164 164
      */
165 165
     public function isActive()
166 166
     {
167
-        return (1 == $this->getVar('isActive'));// ? true : false;
167
+        return (1 == $this->getVar('isActive')); // ? true : false;
168 168
     }
169 169
 
170 170
     /**
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
      */
173 173
     public function inAdvanced()
174 174
     {
175
-        return (1 == $this->getVar('viewInAdvanced'));// ? true : false;
175
+        return (1 == $this->getVar('viewInAdvanced')); // ? true : false;
176 176
     }
177 177
 
178 178
     /**
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
      */
181 181
     public function isLocked()
182 182
     {
183
-        return (1 == $this->getVar('locked'));// ? true : false;
183
+        return (1 == $this->getVar('locked')); // ? true : false;
184 184
     }
185 185
 
186 186
     /**
@@ -188,7 +188,7 @@  discard block
 block discarded – undo
188 188
      */
189 189
     public function hasSearch()
190 190
     {
191
-        return (1 == $this->getVar('hasSearch'));// ? true : false;
191
+        return (1 == $this->getVar('hasSearch')); // ? true : false;
192 192
     }
193 193
 
194 194
     /**
@@ -196,7 +196,7 @@  discard block
 block discarded – undo
196 196
      */
197 197
     public function addLitter()
198 198
     {
199
-        return (1 == $this->getVar('litter'));// ? true : false;
199
+        return (1 == $this->getVar('litter')); // ? true : false;
200 200
     }
201 201
 
202 202
     /**
@@ -204,7 +204,7 @@  discard block
 block discarded – undo
204 204
      */
205 205
     public function generalLitter()
206 206
     {
207
-        return (1 == $this->getVar('generalLitter'));// ? true : false;
207
+        return (1 == $this->getVar('generalLitter')); // ? true : false;
208 208
     }
209 209
 
210 210
     /**
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
      */
213 213
     public function hasLookup()
214 214
     {
215
-        return (1 == $this->getVar('lookupTable'));// ? true : false;
215
+        return (1 == $this->getVar('lookupTable')); // ? true : false;
216 216
     }
217 217
 
218 218
     /**
@@ -228,7 +228,7 @@  discard block
 block discarded – undo
228 228
      */
229 229
     public function inPie()
230 230
     {
231
-        return (1 == $this->getVar('viewInPie'));// ? true : false;
231
+        return (1 == $this->getVar('viewInPie')); // ? true : false;
232 232
     }
233 233
 
234 234
     /**
@@ -236,7 +236,7 @@  discard block
 block discarded – undo
236 236
      */
237 237
     public function inPedigree()
238 238
     {
239
-        return (1 == $this->getVar('viewInPedigree'));// ? true : false;
239
+        return (1 == $this->getVar('viewInPedigree')); // ? true : false;
240 240
     }
241 241
 
242 242
     /**
@@ -244,7 +244,7 @@  discard block
 block discarded – undo
244 244
      */
245 245
     public function inList()
246 246
     {
247
-        return (1 == $this->getVar('viewInList'));// ? true : false;
247
+        return (1 == $this->getVar('viewInList')); // ? true : false;
248 248
     }
249 249
 
250 250
     /**
Please login to merge, or discard this patch.
class/Field.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -161,7 +161,7 @@  discard block
 block discarded – undo
161 161
     {
162 162
         $ret = [];
163 163
         global $xoopsDB;
164
-        $SQL    = 'SELECT * FROM ' . $GLOBALS['xoopsDB']->prefix("pedigree_lookup{$fieldnumber}") . " ORDER BY 'order'";
164
+        $SQL    = 'SELECT * FROM '.$GLOBALS['xoopsDB']->prefix("pedigree_lookup{$fieldnumber}")." ORDER BY 'order'";
165 165
         $result = $GLOBALS['xoopsDB']->query($SQL);
166 166
         while (false !== ($row = $GLOBALS['xoopsDB']->fetchArray($result))) {
167 167
             $ret[] = ['id' => $row['id'], 'value' => $row['value']];
@@ -186,7 +186,7 @@  discard block
 block discarded – undo
186 186
      */
187 187
     public function showField()
188 188
     {
189
-        return $this->fieldname . ' : ' . $this->value;
189
+        return $this->fieldname.' : '.$this->value;
190 190
     }
191 191
 
192 192
     /**
Please login to merge, or discard this patch.