XoopsModules25x/apcal

View on GitHub

Showing 26,336 of 26,336 total issues

The parameter $event_id is not named in camelCase.
Open

        public function update_record_after_import($event_id)
        {
            $rs    = $GLOBALS['xoopsDB']->query("SELECT categories,rrule FROM $this->table WHERE id='$event_id'");
            $event = $GLOBALS['xoopsDB']->fetchObject($rs);

Severity: Minor
Found in class/APCal.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

Avoid variables with short names like $rs. Configured minimum length is 3.
Open

            $rs    = $GLOBALS['xoopsDB']->query("SELECT categories,rrule FROM $this->table WHERE id='$event_id'");
Severity: Minor
Found in class/APCal.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The parameter $until_init is not named in camelCase.
Open

        public function rrule_to_form($rrule, $until_init)
        {
            // �ƽ���ͤ�����
            $norrule_checked       = '';
            $daily_checked         = '';
Severity: Minor
Found in class/APCal.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $allday_flag is not named in camelCase.
Open

        public function rrule_from_post($start, $allday_flag)
        {
            // �����֤�̵���ʤ顢̵���Ƕ�ʸ������֤�
            if ($_POST['rrule_freq'] === 'none') {
                return '';
Severity: Minor
Found in class/APCal.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $event_id is not named in camelCase.
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;
Severity: Minor
Found in class/APCal.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $event_id is not named in camelCase.
Open

        public function notify_new_event($event_id)
        {
            $rs    = $GLOBALS['xoopsDB']->query("SELECT summary,admission,categories,class,uid,groupid FROM $this->table WHERE id='$event_id'");
            $event = $GLOBALS['xoopsDB']->fetchObject($rs);

Severity: Minor
Found in class/APCal_xoops.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The class APCal_xoops is not named in CamelCase.
Open

    class APCal_xoops extends APCal
    {
        /**
         * @param $data
         * @return mixed
Severity: Minor
Found in class/APCal_xoops.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

The parameter $get_target is not named in camelCase.
Open

        public function get_blockarray_coming_event($get_target = '', $num = 5, $for_coming = false, $untildays = 0)
        {
            // if( $get_target == '' ) $get_target = $_SERVER['SCRIPT_NAME'] ;
            $now = $for_coming ? time() : $this->unixtime + $this->day_start;

Severity: Minor
Found in class/APCal_xoops.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The class iCal_parser is not named in CamelCase.
Open

class iCal_parser
{
    public $week_start_day = 'Sunday';
    public $timezone       = '+0900';
    public $events         = array();
Severity: Minor
Found in class/iCal_parser.php by phpmd

CamelCaseClassName

Since: 0.2

It is considered best practice to use the CamelCase notation to name classes.

Example

class class_name {
}

Source

The parameter $offset_str is not named in camelCase.
Open

    public function calcOffset($offset_str)
    {
        $sign  = substr($offset_str, 0, 1);
        $hours = substr($offset_str, 1, 2);
        $mins  = substr($offset_str, 3, 2);
Severity: Minor
Found in class/iCal_parser.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

Avoid variables with short names like $rs. Configured minimum length is 3.
Open

            $rs = $GLOBALS['xoopsDB']->query($sql);
Severity: Minor
Found in class/APCal_xoops.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

Avoid variables with short names like $rs. Configured minimum length is 3.
Open

            $rs    = $GLOBALS['xoopsDB']->query("SELECT summary,admission,categories,class,uid,groupid FROM $this->table WHERE id='$event_id'");
Severity: Minor
Found in class/APCal_xoops.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

Avoid variables with short names like $op. Configured minimum length is 3.
Open

            $op             = empty($_GET['op']) ? '' : preg_replace('/[^a-zA-Z0-9_-]/', '', $_GET['op']);
Severity: Minor
Found in class/APCal_xoops.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

The property $_menutop is not named in camelCase.
Open

class APCalAdminMenuHandler
{
    /**
     *
     * @var string
Severity: Minor
Found in class/adminMenu.php by phpmd

CamelCasePropertyName

Since: 0.2

It is considered best practice to use the camelCase notation to name attributes.

Example

class ClassName {
    protected $property_name;
}

Source

The parameter $long_ymdn is not named in camelCase.
Open

        public function get_formtextdateselect($name, $ymd, $long_ymdn = '')
        {
            require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';

            // day of week starting
Severity: Minor
Found in class/APCal_xoops.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $get_target is not named in camelCase.
Open

        public function get_blockarray_date_event($get_target = '')
        {
            // if( $get_target == '' ) $get_target = $_SERVER['SCRIPT_NAME'] ;

            // ������׻����Ĥġ�WHERE��δ�֤˴ؤ���������
Severity: Minor
Found in class/APCal_xoops.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $calendar_name is not named in camelCase.
Open

    public function parse($filename, $calendar_name)
    {
        $ifile = @fopen($filename, 'r');
        if ($ifile === false) {
            return "-1: File cannot open. filename: $filename";
Severity: Minor
Found in class/iCal_parser.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $force_http is not named in camelCase.
Open

        public function import_ics_via_fopen($uri, $force_http = true, $user_uri = '')
        {
            $user_uri = empty($user_uri) ? '' : $uri;
            // changing webcal://* to http://*
            $uri = str_replace('webcal://', 'http://', $uri);
Severity: Minor
Found in class/APCal_xoops.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

The parameter $get_target is not named in camelCase.
Open

        public function get_blockarray_new_event($get_target = '', $num = 5)
        {
            // if( $get_target == '' ) $get_target = $_SERVER['SCRIPT_NAME'] ;

            // tzoffset
Severity: Minor
Found in class/APCal_xoops.php by phpmd

CamelCaseParameterName

Since: 0.2

It is considered best practice to use the camelCase notation to name parameters.

Example

class ClassName {
    public function doSomething($user_name) {
    }
}

Source

Avoid variables with short names like $fp. Configured minimum length is 3.
Open

            $fp = fopen($ics_cache_file, 'w');
Severity: Minor
Found in class/APCal_xoops.php by phpmd

ShortVariable

Since: 0.2

Detects when a field, local, or parameter has a very short name.

Example

class Something {
    private $q = 15; // VIOLATION - Field
    public static function main( array $as ) { // VIOLATION - Formal
        $r = 20 + $this->q; // VIOLATION - Local
        for (int $i = 0; $i < 10; $i++) { // Not a Violation (inside FOR)
            $r += $this->q;
        }
    }
}

Source https://phpmd.org/rules/naming.html#shortvariable

Severity
Category
Status
Source
Language