Showing 9,653 of 9,653 total issues
The property $js_path is not named in camelCase. Open
class MetaCoinSlider extends MetaSlider
{
protected $js_function = 'coinslider';
protected $js_path = 'sliders/coinslider/coin-slider.min.js';
protected $css_path = 'sliders/coinslider/coin-slider-styles.css';
- Read upRead up
- Exclude checks
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 property $carousel_item_margin is not named in camelCase. Open
class MetaFlexSlider extends MetaSlider
{
protected $js_function = 'flexslider';
protected $js_path = 'sliders/flexslider/jquery.flexslider-min.js';
protected $css_path = 'sliders/flexslider/flexslider.css';
- Read upRead up
- Exclude checks
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 $shortcode_settings is not named in camelCase. Open
public function __construct($id, $shortcode_settings)
{
parent::__construct($id, $shortcode_settings);
add_filter('metaslider_flex_slider_parameters', [$this, 'enable_carousel_mode'], 10, 2);
- Read upRead up
- Exclude checks
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 property $js_function is not named in camelCase. Open
class MetaNivoSlider extends MetaSlider
{
protected $js_function = 'nivoSlider';
protected $js_path = 'sliders/nivoslider/jquery.nivo.slider.pack.js';
protected $css_path = 'sliders/nivoslider/nivo-slider.css';
- Read upRead up
- Exclude checks
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 property $css_path is not named in camelCase. Open
class MetaNivoSlider extends MetaSlider
{
protected $js_function = 'nivoSlider';
protected $js_path = 'sliders/nivoslider/jquery.nivo.slider.pack.js';
protected $css_path = 'sliders/nivoslider/nivo-slider.css';
- Read upRead up
- Exclude checks
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 property $js_function is not named in camelCase. Open
class MetaResponsiveSlider extends MetaSlider
{
protected $js_function = 'responsiveSlides';
protected $js_path = 'sliders/responsiveslides/responsiveslides.min.js';
protected $css_path = 'sliders/responsiveslides/responsiveslides.css';
- Read upRead up
- Exclude checks
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 $shortcode_settings is not named in camelCase. Open
public function set_slider($id, $shortcode_settings = [])
{
$type = 'flex';
$settings = array_merge(get_post_meta($id, 'ml-slider_settings', true), $shortcode_settings);
- Read upRead up
- Exclude checks
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 property $js_path is not named in camelCase. Open
class MetaFlexSlider extends MetaSlider
{
protected $js_function = 'flexslider';
protected $js_path = 'sliders/flexslider/jquery.flexslider-min.js';
protected $css_path = 'sliders/flexslider/flexslider.css';
- Read upRead up
- Exclude checks
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 $sort_key is not named in camelCase. Open
private function all_meta_sliders($sort_key = 'date')
{
$sliders = false;
// list the tabs
- Read upRead up
- Exclude checks
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 $id. Configured minimum length is 3. Open
$slider = new MetaSlider($id, []);
- Read upRead up
- Exclude checks
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 $id. Configured minimum length is 3. Open
$id = apply_filters('metaslider_container_id', $container_id, $this->id, $this->settings);
- Read upRead up
- Exclude checks
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 $n. Configured minimum length is 3. Open
public function _generateTreeData(&$arr, $id, $level, &$n)
- Read upRead up
- Exclude checks
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 $item_id is not named in camelCase. Open
function extgalleryNotifyIteminfo($category, $item_id)
{
/** @var Extgallery\PublicPhotoHandler $photoHandler */
/** @var Extgallery\Photo $photo */
- Read upRead up
- Exclude checks
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 property $_photoHandler is not named in camelCase. Open
class CategoryHandler extends Extgallery\PersistableObjectHandler
{
//var $_nestedTree;
public $_photoHandler;
- Read upRead up
- Exclude checks
CamelCasePropertyName
Since: 0.2
It is considered best practice to use the camelCase notation to name attributes.
Example
class ClassName {
protected $property_name;
}
Source
Avoid variables with short names like $id. Configured minimum length is 3. Open
public function nbAlbum($id = 0)
- Read upRead up
- Exclude checks
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 $textarea_id is not named in camelCase. Open
public function encode($textarea_id)
{
\xoops_loadLanguage('extention', 'extgallery');
/* $code = "<img src='"
- Read upRead up
- Exclude checks
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 $as_object is not named in camelCase. Open
public function &getObjects(CriteriaElement $criteria = null, $id_as_key = false, $as_object = true)
{
$objects = &$this->getAll($criteria, null, $as_object, $id_as_key);
return $objects;
- Read upRead up
- Exclude checks
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 $parent_id is not named in camelCase. Open
public function isChildOf($child_id, $parent_id)
{
$query = \sprintf('SELECT COUNT(*) AS is_child FROM `%s` WHERE `%s` = %d AND %s = %d', $this->table, $this->fields['id'], $child_id, $this->fields['parent'], $parent_id);
$result = $this->db->query($query);
- Read upRead up
- Exclude checks
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 property $css_path is not named in camelCase. Open
class MetaResponsiveSlider extends MetaSlider
{
protected $js_function = 'responsiveSlides';
protected $js_path = 'sliders/responsiveslides/responsiveslides.min.js';
protected $css_path = 'sliders/responsiveslides/responsiveslides.css';
- Read upRead up
- Exclude checks
CamelCasePropertyName
Since: 0.2
It is considered best practice to use the camelCase notation to name attributes.
Example
class ClassName {
protected $property_name;
}
Source
Avoid variables with short names like $ts. Configured minimum length is 3. Open
public function load($ts)
- Read upRead up
- Exclude checks
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;
}
}
}