XoopsModules25x/apcal

View on GitHub

Showing 26,336 of 26,336 total issues

Function sizeOverlayBox has 31 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        sizeOverlayBox: function (doWrapper, doPanels) {
            var overlayBox = this.overlayBox,
                x = this.x,
                y = this.y;
            hs.setStyles(overlayBox, {
Severity: Minor
Found in assets/images/js/highslide/highslide-full.js - About 1 hr to fix

    Function Outline has 31 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        hs.Outline = function (outlineType, onLoad) {
            this.onLoad = onLoad;
            this.outlineType = outlineType;
            var v = hs.uaVersion, tr;
    
    
    Severity: Minor
    Found in assets/images/js/highslide/highslide-with-gallery.js - About 1 hr to fix

      Function Outline has 31 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          hs.Outline = function (outlineType, onLoad) {
              this.onLoad = onLoad;
              this.outlineType = outlineType;
              var v = hs.uaVersion, tr;
      
      
      Severity: Minor
      Found in assets/images/js/highslide/highslide.js - About 1 hr to fix

        Function sizeOverlayBox has 31 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

                sizeOverlayBox: function (doWrapper, doPanels) {
                    var overlayBox = this.overlayBox,
                        x = this.x,
                        y = this.y;
                    hs.setStyles(overlayBox, {
        Severity: Minor
        Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

          Function justify has 31 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  justify: function (p, moveOnly) {
                      var tgtArr, tgt = p.target, dim = p == this.x ? 'x' : 'y';
          
                      var hasMovedMin = false;
          
          
          Severity: Minor
          Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

            Function Outline has 31 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                hs.Outline = function (outlineType, onLoad) {
                    this.onLoad = onLoad;
                    this.outlineType = outlineType;
                    var v = hs.uaVersion, tr;
            
            
            Severity: Minor
            Found in assets/images/js/highslide/highslide-with-html.js - About 1 hr to fix

              Method apcal_thedays_schedule_show_tpl has 31 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                  function apcal_thedays_schedule_show_tpl($options)
                  {
                      global $xoopsConfig, $xoopsDB;
              
                      $moduleDirName = empty($options[0]) ? basename(dirname(__DIR__)) : $options[0];
              Severity: Minor
              Found in blocks/apcal_thedays_schedule.php - About 1 hr to fix

                Method get_daily has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        public function get_daily($get_target = '', $query_string = '', $for_print = false)
                        {
                            // $PHP_SELF = $_SERVER['SCRIPT_NAME'] ;
                            // if( $get_target == '' ) $get_target = $PHP_SELF ;
                
                
                Severity: Minor
                Found in class/APCal.php - About 1 hr to fix

                  Method get_weekly has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                          public function get_weekly($get_target = '', $query_string = '', $for_print = false)
                          {
                              // $PHP_SELF = $_SERVER['SCRIPT_NAME'] ;
                              // if( $get_target == '' ) $get_target = $PHP_SELF ;
                  
                  
                  Severity: Minor
                  Found in class/APCal.php - About 1 hr to fix

                    Method Crop has 31 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                        public function Crop(&$gdimg, $left = 0, $right = 0, $top = 0, $bottom = 0)
                        {
                            if (!$left && !$right && !$top && !$bottom) {
                                return true;
                            }
                    Severity: Minor
                    Found in thumbs/phpthumb.filters.php - About 1 hr to fix

                      Method savepictures has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                              public function savepictures($event_id)
                              {
                                  xoops_load('xoopsmediauploader');
                                  $uploader = new XoopsMediaUploader(XOOPS_UPLOAD_PATH . '/apcal', array(
                                      'image/gif',
                      Severity: Minor
                      Found in class/APCal.php - About 1 hr to fix

                        Method EnsureDirectoryExists has 30 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                            public static function EnsureDirectoryExists($dirname)
                            {
                                $directory_elements = explode(DIRECTORY_SEPARATOR, $dirname);
                                $startoffset        = (!$directory_elements[0] ? 2 : 1);  // unix with leading "/" then start with 2nd element; Windows with leading "c:\" then start with 1st element
                                $open_basedirs      = preg_split('#[;:]#', ini_get('open_basedir'));
                        Severity: Minor
                        Found in thumbs/phpthumb.functions.php - About 1 hr to fix

                          Similar blocks of code found in 4 locations. Consider refactoring.
                          Open

                                          hs.hideIframes = ((window.opera && hs.uaVersion < 9) || navigator.vendor == 'KDE'
                                          || (hs.ieLt7 && hs.uaVersion < 5.5));
                          Severity: Major
                          Found in assets/images/js/highslide/highslide-full.js and 3 other locations - About 1 hr to fix
                          assets/images/js/highslide/highslide-with-gallery.js on lines 794..795
                          assets/images/js/highslide/highslide-with-html.js on lines 786..787
                          assets/images/js/highslide/highslide.js on lines 621..622

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 59.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 4 locations. Consider refactoring.
                          Open

                                          hs.hideIframes = ((window.opera && hs.uaVersion < 9) || navigator.vendor == 'KDE'
                                          || (hs.ieLt7 && hs.uaVersion < 5.5));
                          Severity: Major
                          Found in assets/images/js/highslide/highslide.js and 3 other locations - About 1 hr to fix
                          assets/images/js/highslide/highslide-full.js on lines 972..973
                          assets/images/js/highslide/highslide-with-gallery.js on lines 794..795
                          assets/images/js/highslide/highslide-with-html.js on lines 786..787

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 59.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 4 locations. Consider refactoring.
                          Open

                                          hs.hideIframes = ((window.opera && hs.uaVersion < 9) || navigator.vendor == 'KDE'
                                          || (hs.ieLt7 && hs.uaVersion < 5.5));
                          Severity: Major
                          Found in assets/images/js/highslide/highslide-with-gallery.js and 3 other locations - About 1 hr to fix
                          assets/images/js/highslide/highslide-full.js on lines 972..973
                          assets/images/js/highslide/highslide-with-html.js on lines 786..787
                          assets/images/js/highslide/highslide.js on lines 621..622

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 59.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Similar blocks of code found in 4 locations. Consider refactoring.
                          Open

                                          hs.hideIframes = ((window.opera && hs.uaVersion < 9) || navigator.vendor == 'KDE'
                                          || (hs.ieLt7 && hs.uaVersion < 5.5));
                          Severity: Major
                          Found in assets/images/js/highslide/highslide-with-html.js and 3 other locations - About 1 hr to fix
                          assets/images/js/highslide/highslide-full.js on lines 972..973
                          assets/images/js/highslide/highslide-with-gallery.js on lines 794..795
                          assets/images/js/highslide/highslide.js on lines 621..622

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 59.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Identical blocks of code found in 6 locations. Consider refactoring.
                          Open

                          if (function_exists('weblog_create_permissionsql')) {
                              $moduleHandler                 = xoops_getHandler('module');
                              $weblogmodule_configHandler = xoops_getHandler('config');
                              $mod_weblog                  = $moduleHandler->getByDirname($plugin['dirname']);
                              $weblog_config               = $weblogmodule_configHandler->getConfigList($mod_weblog->mid());
                          Severity: Major
                          Found in plugins/daily/weblog-date.php and 5 other locations - About 1 hr to fix
                          plugins/daily/weblog-blogid.php on lines 56..65
                          plugins/monthly/weblog-blogid.php on lines 56..64
                          plugins/monthly/weblog-date.php on lines 56..64
                          plugins/weekly/weblog-blogid.php on lines 56..65
                          plugins/weekly/weblog-date.php on lines 57..65

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 104.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Identical blocks of code found in 6 locations. Consider refactoring.
                          Open

                          if (function_exists('weblog_create_permissionsql')) {
                              $moduleHandler                 = xoops_getHandler('module');
                              $weblogmodule_configHandler = xoops_getHandler('config');
                              $mod_weblog                  = $moduleHandler->getByDirname($plugin['dirname']);
                              $weblog_config               = $weblogmodule_configHandler->getConfigList($mod_weblog->mid());
                          Severity: Major
                          Found in plugins/monthly/weblog-blogid.php and 5 other locations - About 1 hr to fix
                          plugins/daily/weblog-blogid.php on lines 56..65
                          plugins/daily/weblog-date.php on lines 56..64
                          plugins/monthly/weblog-date.php on lines 56..64
                          plugins/weekly/weblog-blogid.php on lines 56..65
                          plugins/weekly/weblog-date.php on lines 57..65

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 104.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Identical blocks of code found in 6 locations. Consider refactoring.
                          Open

                          if (function_exists('weblog_create_permissionsql')) {
                              // get weblog config values
                              $moduleHandler                 = xoops_getHandler('module');
                              $weblogmodule_configHandler = xoops_getHandler('config');
                              $mod_weblog                  = $moduleHandler->getByDirname($plugin['dirname']);
                          Severity: Major
                          Found in plugins/weekly/weblog-blogid.php and 5 other locations - About 1 hr to fix
                          plugins/daily/weblog-blogid.php on lines 56..65
                          plugins/daily/weblog-date.php on lines 56..64
                          plugins/monthly/weblog-blogid.php on lines 56..64
                          plugins/monthly/weblog-date.php on lines 56..64
                          plugins/weekly/weblog-date.php on lines 57..65

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 104.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Identical blocks of code found in 6 locations. Consider refactoring.
                          Open

                          if (function_exists('weblog_create_permissionsql')) {
                              $moduleHandler                 = xoops_getHandler('module');
                              $weblogmodule_configHandler = xoops_getHandler('config');
                              $mod_weblog                  = $moduleHandler->getByDirname($plugin['dirname']);
                              $weblog_config               = $weblogmodule_configHandler->getConfigList($mod_weblog->mid());
                          Severity: Major
                          Found in plugins/monthly/weblog-date.php and 5 other locations - About 1 hr to fix
                          plugins/daily/weblog-blogid.php on lines 56..65
                          plugins/daily/weblog-date.php on lines 56..64
                          plugins/monthly/weblog-blogid.php on lines 56..64
                          plugins/weekly/weblog-blogid.php on lines 56..65
                          plugins/weekly/weblog-date.php on lines 57..65

                          Duplicated Code

                          Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                          Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                          When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                          Tuning

                          This issue has a mass of 104.

                          We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                          The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                          If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                          See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                          Refactorings

                          Further Reading

                          Severity
                          Category
                          Status
                          Source
                          Language