Showing 1,049 of 26,336 total issues
File phpthumb.functions.php
has 985 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
//////////////////////////////////////////////////////////////
// phpThumb() by James Heinrich <info@silisoftware.com> //
// available at http://phpthumb.sourceforge.net //
// and/or https://github.com/JamesHeinrich/phpThumb //
Function parse
has a Cognitive Complexity of 116 (exceeds 5 allowed). Consider refactoring. Open
public function parse($filename, $calendar_name)
{
$ifile = @fopen($filename, 'r');
if ($ifile === false) {
return "-1: File cannot open. filename: $filename";
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function update_schedule
has a Cognitive Complexity of 115 (exceeds 5 allowed). Consider refactoring. Open
public function update_schedule($set_sql_append = '', $whr_sql_append = '', $notify_callback = null)
{
if ($_POST['summary'] === '') {
$_POST['summary'] = _APCAL_MB_NOSUBJECT;
}
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
File iCal_parser.php
has 939 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
* which is considered copyrighted (c) material of the original comment or credit authors.
Method get_schedule_view_html
has 442 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function get_schedule_view_html($for_print = false)
{
global $xoopsTpl;
$smode = empty($_GET['smode']) ? 'Monthly' : preg_replace('/[^a-zA-Z0-9_-]/', '', $_GET['smode']);
File xoops_version.php
has 896 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
* which is considered copyrighted (c) material of the original comment or credit authors.
Method getid3_bmp
has 435 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function getid3_bmp(&$BMPdata, &$ThisFileInfo, $ExtractPalette = false, $ExtractData = false)
{
// shortcuts
$ThisFileInfo['bmp']['header']['raw'] = array();
Function CleanUpCacheDirectory
has a Cognitive Complexity of 107 (exceeds 5 allowed). Consider refactoring. Open
public function CleanUpCacheDirectory()
{
$this->DebugMessage('CleanUpCacheDirectory() set to purge ('
. (is_null($this->config_cache_maxage) ? 'NULL' : number_format($this->config_cache_maxage / 86400, 1))
. ' days; '
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
File APCal_xoops.php
has 883 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
* which is considered copyrighted (c) material of the original comment or credit authors.
Function get_schedule_edit_html
has a Cognitive Complexity of 106 (exceeds 5 allowed). Consider refactoring. Open
public function get_schedule_edit_html()
{
$editable = $this->editable;
$superedit = $this->superedit;
$deletable = $this->deletable;
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method ApplyFilters
has 423 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function ApplyFilters()
{
if ($this->fltr && is_array($this->fltr)) {
if (!require_once __DIR__ . '/phpthumb.filters.php') {
$this->DebugMessage('Error including "' . __DIR__ . '/phpthumb.filters.php" which is required for applying filters (' . implode(';', $this->fltr) . ')', __FILE__, __LINE__);
File patTemplate.php
has 856 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
/*
* You may not change or alter any portion of this comment or credits
* of supporting developers from this source code or any supporting source code
* which is considered copyrighted (c) material of the original comment or credit authors.
File phpthumb.gif.php
has 851 lines of code (exceeds 250 allowed). Consider refactoring. Open
<?php
///////////////////////////////////////////////////////////////////////////////////////////////////
// GIF Util - (C) 2003 Yamasoft (S/C)
// http://www.yamasoft.com
// All Rights Reserved
Consider simplifying this complex logical expression. Open
if (!hs) {
var hs = {
// Language strings
lang: {
cssDirection: 'ltr',
Method rrule_extract
has 381 lines of code (exceeds 25 allowed). Consider refactoring. Open
public function rrule_extract($event_id)
{
$yrs = $GLOBALS['xoopsDB']->query("SELECT *,TO_DAYS(end_date)-TO_DAYS(start_date) AS date_diff FROM $this->table WHERE id='$event_id'");
if ($GLOBALS['xoopsDB']->getRowsNum($yrs) < 1) {
return;
Function Thumbstrip
has a Cognitive Complexity of 90 (exceeds 5 allowed). Consider refactoring. Open
hs.Thumbstrip = function (slideshow) {
function add(exp) {
hs.extend(options || {}, {
overlayId: dom,
hsId: 'thumbstrip',
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function Thumbstrip
has a Cognitive Complexity of 90 (exceeds 5 allowed). Consider refactoring. Open
hs.Thumbstrip = function (slideshow) {
function add(exp) {
hs.extend(options || {}, {
overlayId: dom,
hsId: 'thumbstrip',
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Consider simplifying this complex logical expression. Open
if (!hs) {
var hs = {
// Language strings
lang: {
cssDirection: 'ltr',
Function WatermarkText
has a Cognitive Complexity of 80 (exceeds 5 allowed). Consider refactoring. Open
public function WatermarkText(
&$gdimg,
$text,
$size,
$alignment,
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function dump
has a Cognitive Complexity of 79 (exceeds 5 allowed). Consider refactoring. Open
public function dump()
{
echo "<style type=\"text/css\">\n";
echo ".text {font-family: Verdana, Arial, sans-serif; font-size: 10px; color: #000000}\n";
echo ".mid {font-family: Verdana, Arial, sans-serif; font-size: 12px; color: #000000}\n";
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"