@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | * @param mixed $debug |
| 59 | 59 | */ |
| 60 | 60 | /** |
| 61 | - * @param $debug |
|
| 61 | + * @param boolean $debug |
|
| 62 | 62 | */ |
| 63 | 63 | public function __construct($debug) |
| 64 | 64 | { |
@@ -106,7 +106,7 @@ discard block |
||
| 106 | 106 | * @param string $name |
| 107 | 107 | */ |
| 108 | 108 | /** |
| 109 | - * @param null $name |
|
| 109 | + * @param string $name |
|
| 110 | 110 | * |
| 111 | 111 | * @return null|string |
| 112 | 112 | */ |
@@ -139,7 +139,7 @@ discard block |
||
| 139 | 139 | * @param null $name |
| 140 | 140 | * @param null $value |
| 141 | 141 | * |
| 142 | - * @return mixed |
|
| 142 | + * @return string |
|
| 143 | 143 | */ |
| 144 | 144 | public function setConfig($name = null, $value = null) |
| 145 | 145 | { |
@@ -157,9 +157,9 @@ discard block |
||
| 157 | 157 | * @param string $name |
| 158 | 158 | */ |
| 159 | 159 | /** |
| 160 | - * @param $name |
|
| 160 | + * @param string $name |
|
| 161 | 161 | * |
| 162 | - * @return mixed |
|
| 162 | + * @return string |
|
| 163 | 163 | */ |
| 164 | 164 | public function &getHandler($name) |
| 165 | 165 | { |
@@ -100,7 +100,7 @@ |
||
| 100 | 100 | * @param $logoIcon |
| 101 | 101 | * @param $moduleDirname |
| 102 | 102 | * |
| 103 | - * @return bool|string |
|
| 103 | + * @return false|string |
|
| 104 | 104 | */ |
| 105 | 105 | public static function createLogo($logoIcon, $moduleDirname) |
| 106 | 106 | { |
@@ -134,7 +134,7 @@ |
||
| 134 | 134 | |
| 135 | 135 | // Write text |
| 136 | 136 | $textColor = imagecolorallocate($imageModule, 0, 0, 0); |
| 137 | - $spaceToBorder = (92 - strlen($moduleDirname) * 7.5) / 2; |
|
| 137 | + $spaceToBorder = (92-strlen($moduleDirname) * 7.5) / 2; |
|
| 138 | 138 | imagefttext($imageModule, 8.5, 0, $spaceToBorder, 45, $textColor, $font, ucfirst($moduleDirname), array()); |
| 139 | 139 | |
| 140 | 140 | imagecopy($imageModule, $imageIcon, 29, 2, 0, 0, 32, 32); |
@@ -63,7 +63,7 @@ |
||
| 63 | 63 | } |
| 64 | 64 | if (!empty($this->columns)) { |
| 65 | 65 | if ($span = $i % $this->columns) { |
| 66 | - $ret .= '<td colspan="'.($this->columns - $span).'"></td></tr>'; |
|
| 66 | + $ret .= '<td colspan="'.($this->columns-$span).'"></td></tr>'; |
|
| 67 | 67 | } |
| 68 | 68 | $ret .= '</table>'; |
| 69 | 69 | } |
@@ -141,7 +141,7 @@ |
||
| 141 | 141 | $namespace = ''; |
| 142 | 142 | if (false !== ($lastNsPos = strripos($className, $this->_namespaceSeparator))) { |
| 143 | 143 | $namespace = substr($className, 0, $lastNsPos); |
| 144 | - $className = substr($className, $lastNsPos + 1); |
|
| 144 | + $className = substr($className, $lastNsPos+1); |
|
| 145 | 145 | $fileName = str_replace($this->_namespaceSeparator, DIRECTORY_SEPARATOR, $namespace).DIRECTORY_SEPARATOR; |
| 146 | 146 | } |
| 147 | 147 | $fileName .= str_replace('_', DIRECTORY_SEPARATOR, $className).$this->_fileExtension; |
@@ -415,7 +415,7 @@ |
||
| 415 | 415 | $imageIcon = imagecreatefrompng($iconFile); |
| 416 | 416 | // Write text |
| 417 | 417 | $textColor = imagecolorallocate($imageModule, 0, 0, 0); |
| 418 | - $spaceBorder = (92 - strlen($moduleDirname) * 7.5) / 2; |
|
| 418 | + $spaceBorder = (92-strlen($moduleDirname) * 7.5) / 2; |
|
| 419 | 419 | imagefttext($imageModule, 8.5, 0, $spaceBorder, 45, $textColor, $font, ucfirst($moduleDirname), array()); |
| 420 | 420 | imagecopy($imageModule, $imageIcon, 29, 2, 0, 0, 32, 32); |
| 421 | 421 | $logoImg = '/'.$moduleDirname.'_logo.png'; |
@@ -375,7 +375,7 @@ discard block |
||
| 375 | 375 | * @param $logoIcon |
| 376 | 376 | * @param $moduleDirname |
| 377 | 377 | * |
| 378 | - * @return bool|string |
|
| 378 | + * @return false|string |
|
| 379 | 379 | */ |
| 380 | 380 | private static function createLogo($logoIcon, $moduleDirname) |
| 381 | 381 | { |
@@ -456,7 +456,7 @@ discard block |
||
| 456 | 456 | |
| 457 | 457 | /** |
| 458 | 458 | * Get Defined Language. |
| 459 | - * @param $lang |
|
| 459 | + * @param string $lang |
|
| 460 | 460 | * |
| 461 | 461 | * @return string |
| 462 | 462 | */ |
@@ -574,10 +574,10 @@ discard block |
||
| 574 | 574 | /** |
| 575 | 575 | * Get Modules Criteria. |
| 576 | 576 | * @param $criteriaModules |
| 577 | - * @param $start |
|
| 578 | - * @param $limit |
|
| 579 | - * @param $sort |
|
| 580 | - * @param $order |
|
| 577 | + * @param integer $start |
|
| 578 | + * @param integer $limit |
|
| 579 | + * @param string $sort |
|
| 580 | + * @param string $order |
|
| 581 | 581 | * @return |
| 582 | 582 | */ |
| 583 | 583 | private function getModulesCriteria($criteriaModules, $start, $limit, $sort, $order) |
@@ -44,9 +44,9 @@ discard block |
||
| 44 | 44 | ); |
| 45 | 45 | |
| 46 | 46 | /** |
| 47 | - * @public function constructor class |
|
| 48 | - * @param null |
|
| 49 | - */ |
|
| 47 | + * @public function constructor class |
|
| 48 | + * @param null |
|
| 49 | + */ |
|
| 50 | 50 | |
| 51 | 51 | public function __construct() |
| 52 | 52 | { |
@@ -109,8 +109,8 @@ discard block |
||
| 109 | 109 | } |
| 110 | 110 | |
| 111 | 111 | /** |
| 112 | - * @static function getInstance |
|
| 113 | - * @param null |
|
| 112 | + * @static function getInstance |
|
| 113 | + * @param null |
|
| 114 | 114 | * @return TDMCreateModules |
| 115 | 115 | */ |
| 116 | 116 | public static function getInstance() |
@@ -124,8 +124,8 @@ discard block |
||
| 124 | 124 | } |
| 125 | 125 | |
| 126 | 126 | /** |
| 127 | - * @public function getFormModules |
|
| 128 | - * @param mixed $action |
|
| 127 | + * @public function getFormModules |
|
| 128 | + * @param mixed $action |
|
| 129 | 129 | * |
| 130 | 130 | * @return XoopsThemeForm |
| 131 | 131 | */ |
@@ -356,9 +356,9 @@ discard block |
||
| 356 | 356 | } |
| 357 | 357 | |
| 358 | 358 | /** |
| 359 | - * @private static function createLogo |
|
| 360 | - * @param mixed $logoIcon |
|
| 361 | - * @param string $moduleDirname |
|
| 359 | + * @private static function createLogo |
|
| 360 | + * @param mixed $logoIcon |
|
| 361 | + * @param string $moduleDirname |
|
| 362 | 362 | * |
| 363 | 363 | * @return bool|string |
| 364 | 364 | */ |
@@ -95,7 +95,7 @@ |
||
| 95 | 95 | $nb_fieldSearch = count($fieldSearch); |
| 96 | 96 | $sql .= '('; |
| 97 | 97 | for ($i = 0; $i < $nb_fieldSearch; ++$i) { |
| 98 | - if ($i != $nb_fieldSearch - 1) { |
|
| 98 | + if ($i != $nb_fieldSearch-1) { |
|
| 99 | 99 | $sql .= ''.$fieldSearch[$i].' LIKE %$queryarray['.$options.']% OR '; |
| 100 | 100 | } else { |
| 101 | 101 | $sql .= ''.$fieldSearch[$i].' LIKE %$queryarray[0]%'; |
@@ -28,9 +28,9 @@ discard block |
||
| 28 | 28 | class IncludeSearch extends TDMCreateFile |
| 29 | 29 | { |
| 30 | 30 | /** |
| 31 | - * @public function constructor |
|
| 32 | - * @param null |
|
| 33 | - */ |
|
| 31 | + * @public function constructor |
|
| 32 | + * @param null |
|
| 33 | + */ |
|
| 34 | 34 | |
| 35 | 35 | public function __construct() |
| 36 | 36 | { |
@@ -39,8 +39,8 @@ discard block |
||
| 39 | 39 | } |
| 40 | 40 | |
| 41 | 41 | /** |
| 42 | - * @static function getInstance |
|
| 43 | - * @param null |
|
| 42 | + * @static function getInstance |
|
| 43 | + * @param null |
|
| 44 | 44 | * @return IncludeSearch |
| 45 | 45 | */ |
| 46 | 46 | public static function getInstance() |
@@ -54,10 +54,10 @@ discard block |
||
| 54 | 54 | } |
| 55 | 55 | |
| 56 | 56 | /** |
| 57 | - * @public function write |
|
| 58 | - * @param string $module |
|
| 59 | - * @param mixed $table |
|
| 60 | - * @param string $filename |
|
| 57 | + * @public function write |
|
| 58 | + * @param string $module |
|
| 59 | + * @param mixed $table |
|
| 60 | + * @param string $filename |
|
| 61 | 61 | */ |
| 62 | 62 | public function write($module, $table, $filename) |
| 63 | 63 | { |
@@ -67,9 +67,9 @@ discard block |
||
| 67 | 67 | } |
| 68 | 68 | |
| 69 | 69 | /** |
| 70 | - * @static function getSearchField |
|
| 71 | - * @param string $fieldSearch |
|
| 72 | - * @param string $options |
|
| 70 | + * @static function getSearchField |
|
| 71 | + * @param string $fieldSearch |
|
| 72 | + * @param string $options |
|
| 73 | 73 | * |
| 74 | 74 | * @return string |
| 75 | 75 | */ |
@@ -94,7 +94,7 @@ discard block |
||
| 94 | 94 | } |
| 95 | 95 | |
| 96 | 96 | /** |
| 97 | - * @static function getSearchFunction |
|
| 97 | + * @static function getSearchFunction |
|
| 98 | 98 | * @param $moduleDirname |
| 99 | 99 | * |
| 100 | 100 | * @return string |
@@ -162,8 +162,8 @@ discard block |
||
| 162 | 162 | } |
| 163 | 163 | |
| 164 | 164 | /** |
| 165 | - * @public function render |
|
| 166 | - * @param null |
|
| 165 | + * @public function render |
|
| 166 | + * @param null |
|
| 167 | 167 | * @return bool|string |
| 168 | 168 | */ |
| 169 | 169 | public function render() |
@@ -99,7 +99,7 @@ |
||
| 99 | 99 | if (strpos($fieldName, '_')) { |
| 100 | 100 | $str = strpos($fieldName, '_'); |
| 101 | 101 | if ($str !== false) { |
| 102 | - $rpFieldName = substr($fieldName, $str + 1, strlen($fieldName)); |
|
| 102 | + $rpFieldName = substr($fieldName, $str+1, strlen($fieldName)); |
|
| 103 | 103 | } |
| 104 | 104 | } |
| 105 | 105 | $lpFieldName = substr($fieldName, 0, strpos($fieldName, '_')); |
@@ -253,7 +253,7 @@ |
||
| 253 | 253 | * @param null |
| 254 | 254 | */ |
| 255 | 255 | /** |
| 256 | - * @return bool|string |
|
| 256 | + * @return null|string |
|
| 257 | 257 | */ |
| 258 | 258 | public function render() |
| 259 | 259 | { |
@@ -28,19 +28,19 @@ discard block |
||
| 28 | 28 | class UserRss extends TDMCreateFile |
| 29 | 29 | { |
| 30 | 30 | /** |
| 31 | - * @var mixed |
|
| 32 | - */ |
|
| 31 | + * @var mixed |
|
| 32 | + */ |
|
| 33 | 33 | private $usercode = null; |
| 34 | 34 | |
| 35 | 35 | /** |
| 36 | - * @var string |
|
| 37 | - */ |
|
| 36 | + * @var string |
|
| 37 | + */ |
|
| 38 | 38 | private $xoopscode = null; |
| 39 | 39 | |
| 40 | 40 | /** |
| 41 | - * @public function constructor |
|
| 42 | - * @param null |
|
| 43 | - */ |
|
| 41 | + * @public function constructor |
|
| 42 | + * @param null |
|
| 43 | + */ |
|
| 44 | 44 | |
| 45 | 45 | |
| 46 | 46 | public function __construct() |
@@ -52,8 +52,8 @@ discard block |
||
| 52 | 52 | } |
| 53 | 53 | |
| 54 | 54 | /** |
| 55 | - * @static function getInstance |
|
| 56 | - * @param null |
|
| 55 | + * @static function getInstance |
|
| 56 | + * @param null |
|
| 57 | 57 | * @return UserRss |
| 58 | 58 | */ |
| 59 | 59 | public static function getInstance() |
@@ -67,10 +67,10 @@ discard block |
||
| 67 | 67 | } |
| 68 | 68 | |
| 69 | 69 | /** |
| 70 | - * @public function write |
|
| 71 | - * @param string $module |
|
| 72 | - * @param mixed $table |
|
| 73 | - * @param string $filename |
|
| 70 | + * @public function write |
|
| 71 | + * @param string $module |
|
| 72 | + * @param mixed $table |
|
| 73 | + * @param string $filename |
|
| 74 | 74 | */ |
| 75 | 75 | public function write($module, $table, $filename) |
| 76 | 76 | { |
@@ -80,9 +80,9 @@ discard block |
||
| 80 | 80 | } |
| 81 | 81 | |
| 82 | 82 | /** |
| 83 | - * @public function getUserRss |
|
| 84 | - * @param string $moduleDirname |
|
| 85 | - * @param string $language |
|
| 83 | + * @public function getUserRss |
|
| 84 | + * @param string $moduleDirname |
|
| 85 | + * @param string $language |
|
| 86 | 86 | * |
| 87 | 87 | * @return string |
| 88 | 88 | */ |
@@ -200,8 +200,8 @@ discard block |
||
| 200 | 200 | } |
| 201 | 201 | |
| 202 | 202 | /** |
| 203 | - * @public function render |
|
| 204 | - * @param null |
|
| 203 | + * @public function render |
|
| 204 | + * @param null |
|
| 205 | 205 | * @return bool|string |
| 206 | 206 | */ |
| 207 | 207 | public function render() |
@@ -27,7 +27,7 @@ |
||
| 27 | 27 | */ |
| 28 | 28 | // Autoload Function |
| 29 | 29 | ini_set('display_errors', 1); |
| 30 | -error_reporting(E_ALL | E_STRICT); |
|
| 30 | +error_reporting(E_ALL|E_STRICT); |
|
| 31 | 31 | |
| 32 | 32 | if (!function_exists('application_autoloader')) { |
| 33 | 33 | function application_autoloader($class) |
@@ -90,29 +90,29 @@ discard block |
||
| 90 | 90 | $moduleDirname = preg_replace('/[^a-zA-Z0-9]\s+/', '', strtolower($_POST['mod_dirname'])); |
| 91 | 91 | //Form module save |
| 92 | 92 | $modulesObj->setVars(array( |
| 93 | - 'mod_name' => $_POST['mod_name'], |
|
| 94 | - 'mod_dirname' => $moduleDirname, |
|
| 95 | - 'mod_version' => $_POST['mod_version'], |
|
| 96 | - 'mod_since' => $_POST['mod_since'], |
|
| 97 | - 'mod_min_php' => $_POST['mod_min_php'], |
|
| 98 | - 'mod_min_xoops' => $_POST['mod_min_xoops'], |
|
| 99 | - 'mod_min_admin' => $_POST['mod_min_admin'], |
|
| 100 | - 'mod_min_mysql' => $_POST['mod_min_mysql'], |
|
| 101 | - 'mod_description' => $_POST['mod_description'], |
|
| 102 | - 'mod_author' => $_POST['mod_author'], |
|
| 103 | - 'mod_author_mail' => $_POST['mod_author_mail'], |
|
| 104 | - 'mod_author_website_url' => $_POST['mod_author_website_url'], |
|
| 105 | - 'mod_author_website_name' => $_POST['mod_author_website_name'], |
|
| 106 | - 'mod_credits' => $_POST['mod_credits'], |
|
| 107 | - 'mod_license' => $_POST['mod_license'], |
|
| 108 | - 'mod_release_info' => $_POST['mod_release_info'], |
|
| 109 | - 'mod_release_file' => $_POST['mod_release_file'], |
|
| 110 | - 'mod_manual' => $_POST['mod_manual'], |
|
| 111 | - 'mod_manual_file' => $_POST['mod_manual_file'], )); |
|
| 93 | + 'mod_name' => $_POST['mod_name'], |
|
| 94 | + 'mod_dirname' => $moduleDirname, |
|
| 95 | + 'mod_version' => $_POST['mod_version'], |
|
| 96 | + 'mod_since' => $_POST['mod_since'], |
|
| 97 | + 'mod_min_php' => $_POST['mod_min_php'], |
|
| 98 | + 'mod_min_xoops' => $_POST['mod_min_xoops'], |
|
| 99 | + 'mod_min_admin' => $_POST['mod_min_admin'], |
|
| 100 | + 'mod_min_mysql' => $_POST['mod_min_mysql'], |
|
| 101 | + 'mod_description' => $_POST['mod_description'], |
|
| 102 | + 'mod_author' => $_POST['mod_author'], |
|
| 103 | + 'mod_author_mail' => $_POST['mod_author_mail'], |
|
| 104 | + 'mod_author_website_url' => $_POST['mod_author_website_url'], |
|
| 105 | + 'mod_author_website_name' => $_POST['mod_author_website_name'], |
|
| 106 | + 'mod_credits' => $_POST['mod_credits'], |
|
| 107 | + 'mod_license' => $_POST['mod_license'], |
|
| 108 | + 'mod_release_info' => $_POST['mod_release_info'], |
|
| 109 | + 'mod_release_file' => $_POST['mod_release_file'], |
|
| 110 | + 'mod_manual' => $_POST['mod_manual'], |
|
| 111 | + 'mod_manual_file' => $_POST['mod_manual_file'], )); |
|
| 112 | 112 | //Form mod_image |
| 113 | 113 | include_once XOOPS_ROOT_PATH.'/class/uploader.php'; |
| 114 | 114 | $uploader = new XoopsMediaUploader(TDMC_UPLOAD_IMGMOD_PATH, $tdmcreate->getConfig('mimetypes'), |
| 115 | - $tdmcreate->getConfig('maxsize'), null, null); |
|
| 115 | + $tdmcreate->getConfig('maxsize'), null, null); |
|
| 116 | 116 | if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) { |
| 117 | 117 | $uploader->fetchMedia($_POST['xoops_upload_file'][0]); |
| 118 | 118 | if (!$uploader->upload()) { |
@@ -126,16 +126,16 @@ discard block |
||
| 126 | 126 | } |
| 127 | 127 | //Form module save |
| 128 | 128 | $modulesObj->setVars(array( |
| 129 | - 'mod_demo_site_url' => $_POST['mod_demo_site_url'], |
|
| 130 | - 'mod_demo_site_name' => $_POST['mod_demo_site_name'], |
|
| 131 | - 'mod_support_url' => $_POST['mod_support_url'], |
|
| 132 | - 'mod_support_name' => $_POST['mod_support_name'], |
|
| 133 | - 'mod_website_url' => $_POST['mod_website_url'], |
|
| 134 | - 'mod_website_name' => $_POST['mod_website_name'], |
|
| 135 | - 'mod_release' => $_POST['mod_release'], |
|
| 136 | - 'mod_status' => $_POST['mod_status'], |
|
| 137 | - 'mod_donations' => $_POST['mod_donations'], |
|
| 138 | - 'mod_subversion' => $_POST['mod_subversion'], ) |
|
| 129 | + 'mod_demo_site_url' => $_POST['mod_demo_site_url'], |
|
| 130 | + 'mod_demo_site_name' => $_POST['mod_demo_site_name'], |
|
| 131 | + 'mod_support_url' => $_POST['mod_support_url'], |
|
| 132 | + 'mod_support_name' => $_POST['mod_support_name'], |
|
| 133 | + 'mod_website_url' => $_POST['mod_website_url'], |
|
| 134 | + 'mod_website_name' => $_POST['mod_website_name'], |
|
| 135 | + 'mod_release' => $_POST['mod_release'], |
|
| 136 | + 'mod_status' => $_POST['mod_status'], |
|
| 137 | + 'mod_donations' => $_POST['mod_donations'], |
|
| 138 | + 'mod_subversion' => $_POST['mod_subversion'], ) |
|
| 139 | 139 | ); |
| 140 | 140 | $moduleOption = XoopsRequest::getArray('module_option', array()); |
| 141 | 141 | $modulesObj->setVar('mod_admin', in_array('admin', $moduleOption)); |
@@ -108,7 +108,7 @@ discard block |
||
| 108 | 108 | 'mod_release_info' => $_POST['mod_release_info'], |
| 109 | 109 | 'mod_release_file' => $_POST['mod_release_file'], |
| 110 | 110 | 'mod_manual' => $_POST['mod_manual'], |
| 111 | - 'mod_manual_file' => $_POST['mod_manual_file'], )); |
|
| 111 | + 'mod_manual_file' => $_POST['mod_manual_file'],)); |
|
| 112 | 112 | //Form mod_image |
| 113 | 113 | include_once XOOPS_ROOT_PATH.'/class/uploader.php'; |
| 114 | 114 | $uploader = new XoopsMediaUploader(TDMC_UPLOAD_IMGMOD_PATH, $tdmcreate->getConfig('mimetypes'), |
@@ -116,7 +116,7 @@ discard block |
||
| 116 | 116 | if ($uploader->fetchMedia($_POST['xoops_upload_file'][0])) { |
| 117 | 117 | $uploader->fetchMedia($_POST['xoops_upload_file'][0]); |
| 118 | 118 | if (!$uploader->upload()) { |
| 119 | - $errors =& $uploader->getErrors(); |
|
| 119 | + $errors = & $uploader->getErrors(); |
|
| 120 | 120 | redirect_header('javascript:history.go(-1)', 3, $errors); |
| 121 | 121 | } else { |
| 122 | 122 | $modulesObj->setVar('mod_image', $uploader->getSavedFileName()); |
@@ -135,7 +135,7 @@ discard block |
||
| 135 | 135 | 'mod_release' => $_POST['mod_release'], |
| 136 | 136 | 'mod_status' => $_POST['mod_status'], |
| 137 | 137 | 'mod_donations' => $_POST['mod_donations'], |
| 138 | - 'mod_subversion' => $_POST['mod_subversion'], ) |
|
| 138 | + 'mod_subversion' => $_POST['mod_subversion'],) |
|
| 139 | 139 | ); |
| 140 | 140 | $moduleOption = XoopsRequest::getArray('module_option', array()); |
| 141 | 141 | $modulesObj->setVar('mod_admin', in_array('admin', $moduleOption)); |