e107_handlers/form_handler.php
File form_handler.php
has 5402 lines of code (exceeds 2000 allowed). Consider refactoring. Open
Open
<?php
/*
* e107 website system
*
* Copyright (C) 2008-2012 e107 Inc (e107.org)
Method form_textarea
has 9 arguments (exceeds 7 allowed). Consider refactoring. Open
Open
public function form_textarea($form_name, $form_columns, $form_rows, $form_value, $form_js = '', $form_style = '', $form_wrap = '', $form_readonly = '', $form_tooltip = '') {
Consider simplifying this complex logical expression. Open
Open
if ((in_array($key, $columnPref) || ($key === 'options' && isset($val['title'])) || (vartrue($val['forced']))) && !vartrue($val['nolist']))
{
$cl = (vartrue($val['thclass'])) ? " class='".$val['thclass']."'" : '';
$aClass = ($key === $field) ? "sorted-" . $sorted : null;
Method form_text
has 8 arguments (exceeds 7 allowed). Consider refactoring. Open
Open
public function form_text($form_name, $form_size, $form_value, $form_maxlength = FALSE, $form_class = 'tbox form-control', $form_readonly = '', $form_tooltip = '', $form_js = '') {
Method renderInline
has 8 arguments (exceeds 7 allowed). Consider refactoring. Open
Open
public function renderInline($dbField, $pid, $fieldName, $curVal, $linkText, $type='text', $array=null, $options=array())
Method form_password
has 8 arguments (exceeds 7 allowed). Consider refactoring. Open
Open
public function form_password($form_name, $form_size, $form_value, $form_maxlength = FALSE, $form_class = 'tbox form-control', $form_readonly = '', $form_tooltip = '', $form_js = '') {
Avoid too many return
statements within this method. Open
Open
return $tp->toGlyph('fa-file','size=2x');
Avoid too many return
statements within this method. Open
Open
return $this->renderInline($field, $id, $attributes['title'], $value, $dispValue, 'select', $wparms, array('class'=>'e-editable-boolean '.$styleClass));
Avoid too many return
statements within this method. Open
Open
return $video;
Avoid too many return
statements within this method. Open
Open
return e107::getMedia()->previewTag($firstItem, $parms);
Avoid too many return
statements within this method. Open
Open
return ($value ?: vartrue($parms['empty']));
Avoid too many return
statements within this method. Open
Open
return $this->renderInline($field,$id,$attributes['title'],$value,substr($value,0,50). '...','textarea'); //FIXME.
Avoid too many return
statements within this method. Open
Open
return $this->renderInline($field, $id, $attributes['title'], $_value, $value, 'select', $wparms);
Avoid too many return
statements within this method. Open
Open
return $value;
Avoid too many return
statements within this method. Open
Open
return $ret;
Avoid too many return
statements within this method. Open
Open
return "<span class='label label-important label-danger' title='".$className. '::' .$meth."'>Missing Method</span>";
Avoid too many return
statements within this method. Open
Open
return $tp->toImage($value, $thparms);
Avoid too many return
statements within this method. Open
Open
return "Type 'files' must have a data type of 'array' or 'json'";
Avoid too many return
statements within this method. Open
Open
return $value;
Avoid too many return
statements within this method. Open
Open
return $ttl;
Avoid too many return
statements within this method. Open
Open
return $tp->replaceConstants(vartrue($parms['pre']) . $value, varset($parms['replace_mod'], 'abs'));
Avoid too many return
statements within this method. Open
Open
return '';
Avoid too many return
statements within this method. Open
Open
return $text;
Suspicious array access to nullable ?array|?array{class:'tbox number e-spinner input-small '}|?array{class:mixed,size:15}|?array{class:mixed}|?array{max:mixed,size:15,class:'tbox number e-spinner input-small '|mixed,type:'number'}|?array{size:15}|?array{type:'number'}|?array{}|array{pattern:'^'}
Open
Open
$attributes['step'] = vartrue($options['step'], '1');
- Exclude checks
Argument 4 (extras)
is array|array{class:'btn btn-sm btn-default'}|array{h:190}|array{h:mixed,w:206|mixed,help:mixed,media:'_common'|mixed}|array{help:mixed,media:'_common'|mixed}|array{icon:mixed,h:190|mixed,w:206|mixed,help:mixed,media:'_common'|mixed}|array{media:'_common'}|array{media:mixed}|array{title:'Add'}|array{type:'icon'}|array{w:206}|array{w:mixed,help:mixed,media:'_common'|mixed}|array{}
but \e_form::mediaUrl()
takes null
defined at /code/e107_handlers/form_handler.php:1100
Open
Open
$editIcon = $this->mediaUrl($cat, $tp->toGlyph('fa-plus', array('fw'=>1)), $name_id,$parms);
- Exclude checks
Argument 3 (dep)
is 'jquery'
but \e107::css()
takes null
defined at /code/e107_handlers/e107_class.php:2692
Open
Open
e107::css('core', 'bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css', 'jquery');
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
$options_on = varset($options['enabled'], array());
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
if(!empty($options['expandit']) || vartrue($options['class']) === 'e-expandit' ) // See admin->prefs 'Single Login' for an example.
- Exclude checks
Variable $defaults
was undeclared, but array fields are being added to it. Open
Open
$defaults['selectize'] = array(
- Exclude checks
Argument 2 (arr2)
is ?array
but \array_replace_recursive()
takes array
Open
Open
$options = array_replace_recursive($defaults, $options);
- Exclude checks
Suspicious array access to nullable ?array|array{pattern:mixed}
Open
Open
$options['required'] = varset($options['required'], 1);
- Exclude checks
Suspicious array access to nullable ?array|?array{class:'tbox number e-spinner input-small '}|?array{class:mixed,size:15}|?array{class:mixed}|?array{max:mixed,size:15,class:'tbox number e-spinner input-small '|mixed,type:'number'}|?array{size:15}|?array{type:'number'}|?array{}|array{pattern:'^'}
Open
Open
if (varset($options['min'], 0) < 0)
- Exclude checks
Argument 4 (extras)
is array|array{class:'btn btn-sm btn-default'}|array{h:190}|array{h:mixed,w:206|mixed,help:mixed,media:'_common'|mixed}|array{help:mixed,media:'_common'|mixed}|array{icon:mixed,h:190|mixed,w:206|mixed,help:mixed,media:'_common'|mixed}|array{media:'_common'}|array{media:mixed}|array{type:'icon'}|array{w:206}|array{w:mixed,help:mixed,media:'_common'|mixed}|array{}
but \e_form::mediaUrl()
takes null
defined at /code/e107_handlers/form_handler.php:1100
Open
Open
$editIcon = $this->mediaUrl($cat, $tp->toGlyph('fa-edit', array('fw'=>1)), $name_id,$parms);
- Exclude checks
Argument 1 (id)
is string
but \user_class::getName()
takes int
defined at /code/e107_handlers/userclass_class.php:954
Open
Open
$cname = e107::getUserClass()->getName($cls);
- Exclude checks
Suspicious array access to nullable ?array|?array{class:'tbox number e-spinner input-small '}|?array{class:mixed,size:15}|?array{class:mixed}|?array{size:15}|?array{}|array{type:'number'}
Open
Open
$attributes['min'] = vartrue($options['min'], '0');
- Exclude checks
Argument 1 (input)
is 1
but \str_pad()
takes string
Open
Open
$attributes['step'] = "0." . str_pad(1, (int) $options['decimals'], 0, STR_PAD_LEFT);
- Exclude checks
Argument 3 (pad_string)
is 0
but \str_pad()
takes string
Open
Open
$attributes['step'] = "0." . str_pad(1, (int) $options['decimals'], 0, STR_PAD_LEFT);
- Exclude checks
Saw possibly unextractable annotation for a fragment of comment '* @param mixed default':
after mixed,
did not see an element name (will guess based on comment order) Open
Open
* @param mixed default
- Exclude checks
Invalid offset "btn-label"
of array type array{}
Open
Open
$striped = (vartrue($options['btn-label'])) ? ' progress-striped active' : '';
- Exclude checks
Invalid offset "active"
of array type array{}
Open
Open
$initTab = varset($options['active'], false);
- Exclude checks
Argument 3 (parms)
is array|array{glyph:1}|array{h:64}|array{icon:1}|array{legacyPath:'\x7be_IMAGE\x7dicons'}|array{legacyPath:mixed,icon:1,glyph:1,w:64,h:64,media:'_icon'}|array{media:'_icon'}|array{w:64}
but \e_form::mediapicker()
takes string
defined at /code/e107_handlers/form_handler.php:1406
Open
Open
return $this->mediapicker($name, $default, $options);
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
$options_off = varset($options['disabled'], array());
- Exclude checks
Invalid offset "glyphs"
of array type array{}
Open
Open
'glyphs' => vartrue($options['glyphs'],false) // 1|0
- Exclude checks
Invalid offset "class"
of array type array{}
Open
Open
$class = vartrue($options['class']);
- Exclude checks
Invalid offset "show"
of array type array{btn-label:mixed,id:mixed,label:mixed}
Open
Open
$text .= '<a id="'.$buttonId.'" data-loading-text="'.$loading.'" data-progress-interval="'.$interval.'" data-progress-target="'.$target.'" data-progress="' . $options['url'] . '" data-progress-mode="'.varset($options['mode'],0).'" data-progress-show="'.varset($options['show'],0).'" data-progress-hide="'.$buttonId.'" class="btn btn-primary e-progress" >'.$options['btn-label'].'</a>';
- Exclude checks
Suspicious type null
of a variable or expression used to build a string. (Expected type to be able to cast to a string) Open
Open
$text .= '<a id="'.$buttonId.'" data-loading-text="'.$loading.'" data-progress-interval="'.$interval.'" data-progress-target="'.$target.'" data-progress="' . $options['url'] . '" data-progress-mode="'.varset($options['mode'],0).'" data-progress-show="'.varset($options['show'],0).'" data-progress-hide="'.$buttonId.'" class="btn btn-primary e-progress" >'.$options['btn-label'].'</a>';
- Exclude checks
Argument 2 (args)
is ?array
but \array_merge()
takes array
Open
Open
$options_on = array_merge($options_on, $options);
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
'type' => varset($options['type']) === 'email' ? 'email' : 'text',
- Exclude checks
Suspicious array access to nullable ?array|array{pattern:mixed}|array{required:mixed}
Open
Open
$options['class'] = vartrue($options['class'],'e-password tbox');
- Exclude checks
Parameter $value
has undeclared type \number
Open
Open
public function progressBar($name,$value,$options=array())
- Exclude checks
Argument 2 (callback)
is array{0:\e_form,1:'_uc_checkbox_cb'}
but \user_class::vetted_tree()
takes \function|object|string
defined at /code/e107_handlers/userclass_class.php:720
Open
Open
'.$this->_uc->vetted_tree($name, array($this, '_uc_checkbox_cb'), $current_value, $uc_options, $field_options).'
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$inner .= $tab['text'];
- Exclude checks
Argument 3 (user_options)
is ?array|?array{class:''|'tbox',selectize:array{copyClassesToDropdown:true}|array{dropdownClass:'selectize-dropdown'}|array{dropdownContentClass:'selectize-dropdown-content'}|array{inputClass:'form-control selectize-input '}|array{wrapperClass:'selectize-control'}|mixed,typeahead:mixed,data-source:string}|?array{class:''}|?array{class:'tbox'}|?array{data-source:string}|?array{selectize:array{copyClassesToDropdown:true}}|?array{selectize:array{dropdownClass:'selectize-dropdown'}}|?array{selectize:array{dropdownContentClass:'selectize-dropdown-content'}}|?array{selectize:array{inputClass:'form-control selectize-input '}}|?array{selectize:array{wrapperClass:'selectize-control'}}|?array{selectize:mixed,class:'tbox'}|?array{size:mixed,class:''|'tbox',selectize:array{copyClassesToDropdown:true}|array{dropdownClass:'selectize-dropdown'}|array{dropdownContentClass:'selectize-dropdown-content'}|array{inputClass:'form-control selectize-input '}|array{wrapperClass:'selectize-control'}|mixed,typeahead:mixed,data-source:string}|?array{typeahead:mixed,class:''|'tbox',selectize:array{copyClassesToDropdown:true}|array{dropdownClass:'selectize-dropdown'}|array{dropdownContentClass:'selectize-dropdown-content'}|array{inputClass:'form-control selectize-input '}|array{wrapperClass:'selectize-control'}|mixed}
but \e_form::format_options()
takes array|string
defined at /code/e107_handlers/form_handler.php:4411
Open
Open
$options = $this->format_options('text', $name, $options);
- Exclude checks
Invalid offset "mode"
of array type array{btn-label:mixed,id:mixed,label:mixed}
Open
Open
$text .= '<a id="'.$buttonId.'" data-loading-text="'.$loading.'" data-progress-interval="'.$interval.'" data-progress-target="'.$target.'" data-progress="' . $options['url'] . '" data-progress-mode="'.varset($options['mode'],0).'" data-progress-show="'.varset($options['show'],0).'" data-progress-hide="'.$buttonId.'" class="btn btn-primary e-progress" >'.$options['btn-label'].'</a>';
- Exclude checks
Argument 5 (opt_options)
is array
but \user_class::vetted_tree()
takes string
defined at /code/e107_handlers/userclass_class.php:720
Open
Open
'.$this->_uc->vetted_tree($name, array($this, '_uc_checkbox_cb'), $current_value, $uc_options, $field_options).'
- Exclude checks
Invalid offset "class"
of array type array{id:mixed}|array{}
Open
Open
$tabClass = varset($options['class'],null);
- Exclude checks
Argument 2 (options)
is string
but \e_parse::thumbUrl()
takes array
defined at /code/e107_handlers/e_parse_class.php:2531
Open
Open
$blankImg = $tp->thumbUrl(e_IMAGE. 'generic/blank_avatar.jpg',$attr);
- Exclude checks
Invalid offset "type"
of array type array{}
Open
Open
'type' => varset($options['type'],'record'), // page|record
- Exclude checks
Argument 1 (parm)
is array{tmpl_prefix:mixed,total:int,amount:int,current:int,url:string,type:mixed,glyphs:mixed}
but \nextprev_shortcode()
takes string
defined at /code/e107_core/shortcodes/single/nextprev.php:58
Open
Open
return nextprev_shortcode($nextprev);
- Exclude checks
Saw possibly unextractable annotation for a fragment of comment '* @param string name':
after string,
did not see an element name (will guess based on comment order) Open
Open
* @param string name
- Exclude checks
Argument 4 (extras)
is array|array{action:'dialog'}|array{mode:'main'}
but \e_form::mediaUrl()
takes null
defined at /code/e107_handlers/form_handler.php:1100
Open
Open
$ret .= $this->mediaUrl($cat, $label,$name_id,$sc_parameters);
- Exclude checks
Argument 3 (user_options)
is ?array|?array{class:mixed}|?array{pattern:mixed,required:mixed,class:mixed}|?array{pattern:mixed}|?array{required:mixed}|?array{size:mixed,pattern:mixed,required:mixed,class:mixed}
but \e_form::format_options()
takes array|string
defined at /code/e107_handlers/form_handler.php:4411
Open
Open
$options = $this->format_options('text', $name, $options);
- Exclude checks
Argument 2 (args)
is ?array
but \array_merge()
takes array
Open
Open
$options_off = array_merge($options_off, $options);
- Exclude checks
Saw possibly unextractable annotation for a fragment of comment '* @param string target - e_REQUEST_URI by default':
after string,
did not see an element name (will guess based on comment order) Open
Open
* @param string target - e_REQUEST_URI by default
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
if (!vartrue($options['class']))
- Exclude checks
Argument #2 of this call to \str_pad
is typically a literal or constant but isn't, but argument #1 (which is typically a variable) is a literal or constant. The arguments may be in the wrong order. Open
Open
$attributes['step'] = "0." . str_pad(1, (int) $options['decimals'], 0, STR_PAD_LEFT);
- Exclude checks
Argument 3 (selected)
is string
but \e_form::select()
takes bool|false
defined at /code/e107_handlers/form_handler.php:3325
Open
Open
return $this->select($name, $arr, $value, $options, $placeholder);
- Exclude checks
Argument 3 (user_options)
is ?array|?array{class:'tbox number e-spinner input-small '}|?array{class:mixed,size:15}|?array{class:mixed}|?array{decimals:mixed,max:mixed,size:15,class:'tbox number e-spinner input-small '|mixed,type:'number',pattern:'^'}|?array{max:mixed,size:15,class:'tbox number e-spinner input-small '|mixed,type:'number'}|?array{pattern:'^'}|?array{pattern:mixed,max:mixed,size:15,class:'tbox number e-spinner input-small '|mixed,type:'number'}|?array{size:15}|?array{type:'number'}|?array{}
but \e_form::format_options()
takes array|string
defined at /code/e107_handlers/form_handler.php:4411
Open
Open
$options = $this->format_options('text', $name, $options);
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
$mode = vartrue($extras['mode'], 'main');
- Exclude checks
Argument 3 (parms)
is array{legacyPath:'\x7be_IMAGE\x7dicons',media:'_icon',h:64,w:64,glyph:1,icon:1}|array{legacyPath:mixed,media:'_icon',h:64,w:64,glyph:1,icon:1}
but \e_form::mediapicker()
takes string
defined at /code/e107_handlers/form_handler.php:1406
Open
Open
return $this->mediapicker($name, $default, $options);
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
$action = vartrue($extras['action'], 'dialog');
- Exclude checks
Argument 3 (selected)
is null
but \e_form::select()
takes bool|false
defined at /code/e107_handlers/form_handler.php:3325
Open
Open
return $this->select($name,$opt,$val,$options, varset($options['default'],null));
- Exclude checks
Argument 3 (parms)
is array|array{dropzone:1}|array{image:1}|array{video:mixed,image:1,dropzone:1}|array{youtube:1}|array{}
but \e_form::mediapicker()
takes string
defined at /code/e107_handlers/form_handler.php:1406
Open
Open
return $this->mediapicker($name, $default, $sc_parameters);
- Exclude checks
Invalid offset "loading"
of array type array{id:mixed,label:mixed}|array{label:mixed}|array{}
Open
Open
$loading = vartrue($options['loading'], defset('LAN_LOADING', 'Loading'));
- Exclude checks
Saw possibly unextractable annotation for a fragment of comment '* @param string label':
after string,
did not see an element name (will guess based on comment order) Open
Open
* @param string label
- Exclude checks
Invalid offset "url"
of array type array{btn-label:mixed,id:mixed,label:mixed}
Open
Open
$text .= '<a id="'.$buttonId.'" data-loading-text="'.$loading.'" data-progress-interval="'.$interval.'" data-progress-target="'.$target.'" data-progress="' . $options['url'] . '" data-progress-mode="'.varset($options['mode'],0).'" data-progress-show="'.varset($options['show'],0).'" data-progress-hide="'.$buttonId.'" class="btn btn-primary e-progress" >'.$options['btn-label'].'</a>';
- Exclude checks
Saw possibly unextractable annotation for a fragment of comment '* @param array|string {':
after array|string,
did not see an element name (will guess based on comment order) Open
Open
* @param array|string {
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
$options['pattern'] = vartrue($options['pattern'],'[\S].{2,}[\S]');
- Exclude checks
Invalid offset "interval"
of array type array{btn-label:mixed,id:mixed,label:mixed}
Open
Open
$interval = vartrue($options['interval'],1000);
- Exclude checks
Suspicious array access to nullable ?array
Open
Open
'maxItems' => vartrue($options['maxItems'], 7),
- Exclude checks
Argument 3 (dep)
is 'jquery'
but \e107::css()
takes null
defined at /code/e107_handlers/e107_class.php:2692
Open
Open
e107::css('core', $css, 'jquery');
- Exclude checks
Argument 4 (extras)
is array|array{class:''}|array{class:'btn btn-sm btn-default'}|array{edit:mixed,h:190|mixed,w:206|mixed,help:mixed,media:'_common'|mixed,icon:mixed,type:'icon',class:'btn btn-sm btn-default',title:'Add'}|array{h:190}|array{h:mixed,w:206|mixed,help:mixed,media:'_common'|mixed}|array{help:mixed,media:'_common'|mixed}|array{icon:mixed,h:190|mixed,w:206|mixed,help:mixed,media:'_common'|mixed}|array{media:'_common'}|array{media:mixed}|array{title:'Add'}|array{type:'icon'}|array{w:206}|array{w:mixed,help:mixed,media:'_common'|mixed}|array{}
but \e_form::mediaUrl()
takes null
defined at /code/e107_handlers/form_handler.php:1100
Open
Open
$editIcon = $this->mediaUrl($cat, '<span><!-- --></span>', $name_id,$parms);
- Exclude checks
Saw possibly unextractable annotation for a fragment of comment '* @param mixed sc_parameters':
after mixed,
did not see an element name (will guess based on comment order) Open
Open
* @param mixed sc_parameters
- Exclude checks
Invalid offset "template"
of array type array{}
Open
Open
'tmpl_prefix' => varset($options['template'],'default'),
- Exclude checks
Variable $search
was undeclared, but array fields are being added to it. Open
Open
$search[] = '{'.$k.'}';
- Exclude checks
Saw possibly unextractable annotation for a fragment of comment '* @param string name eg. 'myfield' or 'myfield[]'':
after string,
did not see an element name (will guess based on comment order) Open
Open
* @param string name eg. 'myfield' or 'myfield[]'
- Exclude checks
Argument 4 (options)
is array|array<string>|array{label:'Enabled'|mixed}</string>
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text = $this->radio($name, 1, $checked_enabled, $options_on) . ' ' . $this->radio($name, 0, !$checked_enabled, $options_off);
- Exclude checks
Variable $options_off
was undeclared, but array fields are being added to it. Open
Open
$options_off['label'] = $on;
- Exclude checks
Argument 2 (str)
is true
but \explode()
takes string
Open
Open
$current_value = explode(',', $current_value);
- Exclude checks
Invalid offset "class"
of array type array{title:'ID',width:'5%',forced:true}|array{title:'Options',forced:true,width:'10%',thclass:'center last'}|array{title:'Poll Answers',type:'text',width:'auto',thclass:'left'}|array{title:'Poll Question',width:'auto'}|array{title:'Userclass',type:'text',width:'auto'}
Open
Open
$class = vartrue($val['class']) ? 'class="'.$val['class'].'"' : '';
- Exclude checks
Invalid offset "nolist"
of array type array{title:'Lang Prefix',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lower Threshold',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Image',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Name',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title?:null,type:'text',width:'auto',thclass:'left',class:'left'}
Open
Open
if ((in_array($key, $columnPref) || ($key === 'options' && isset($val['title'])) || (vartrue($val['forced']))) && !vartrue($val['nolist']))
- Exclude checks
Invalid offset "title"
of array type array{pk:int,url:mixed|string}|array{url:mixed}|array{url:string}
Open
Open
$title = varset($options['title'], (LAN_EDIT . ' ' . $fieldName));
- Exclude checks
Call to undeclared method \e_form::getController
Open
Open
$controller = $this->getController();
- Exclude checks
Call to deprecated function \e_parse::text_truncate()
defined at /code/e107_handlers/e_parse_class.php:1286
Open
Open
$value = $tp->text_truncate($value, $parms['truncate'], '...');
- Exclude checks
Suspicious array access to ?mixed
Open
Open
' .vartrue($options['fieldset_pre'])."
- Exclude checks
Suspicious array access to ?mixed
Open
Open
' .vartrue($options['table_pre'])."
- Exclude checks
Suspicious array access to ?mixed
Open
Open
' .$this->thead($fields, $current_fields, varset($options['head_query']), varset($options['query']))."
- Exclude checks
Saw unextractable annotation for comment '* @param @nocontainer'
Open
Open
* @param @nocontainer
- Exclude checks
Argument 5 (opt_options)
is array
but \user_class::vetted_tree()
takes string
defined at /code/e107_handlers/userclass_class.php:720
Open
Open
$text .= $this->_uc->vetted_tree($name, array($this, '_uc_select_cb'), $current_value, $uc_options, $opt_options)."\n";
- Exclude checks
Invalid offset "class"
of array type array{}
Open
Open
$options['class'] = vartrue($options['class']);
- Exclude checks
When fetching an array index from a value of type array,
found an array index of type null,
but expected the index to be of the non-nullable type int|string
Open
Open
$data['readParms']['__nameval'] = $fieldvalues[$data['readParms']['nameField']];
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$url = rawurlencode($url.'?'.(varset($options['np_query']) ? str_replace(array('&', '&'), array('&', '&'), $options['np_query']).'&' : '').'from=[FROM]');
- Exclude checks
Argument 1 (arr1)
is ?array
but \array_merge()
takes array
Open
Open
$options_off = array_merge($options, array('class' => 'e-expandit-off'));
- Exclude checks
Argument 4 (options)
is array|array<string>|array{label:'Enabled'|mixed}</string>
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text = $this->radio($name, 0, !$checked_enabled, $options_on) . ' ' . $this->radio($name, 1, $checked_enabled, $options_off);
- Exclude checks
Call to undeclared method \e_form::getController
Open
Open
$controller = $this->getController();
- Exclude checks
Argument 4 (options)
is string
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text .= "<li class='after-submit'>".$this->radio('__after_submit_action', $k, $selected == $k, 'label=' .$v). '</li>';
- Exclude checks
Argument 4 (options)
is array|array<string>|array{label:'Enabled'|mixed}</string>
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text = $this->radio($name, 0, !$checked_enabled, $options_off) . ' ' . $this->radio($name, 1, $checked_enabled, $options_on);
- Exclude checks
Suspicious array access to nullable ?array{forced:mixed,readParms:array{}}|?array{readParms:array{}}|?mixed
Open
Open
$tdclass = vartrue($data['class']);
- Exclude checks
Variable $options
was undeclared, but array fields are being added to it. Open
Open
$options['selectize'] = array(
- Exclude checks
Call to deprecated function \e_parse::text_truncate()
defined at /code/e107_handlers/e_parse_class.php:1286
Open
Open
$value = $tp->text_truncate($value, $parms['truncate'], '');
- Exclude checks
Call to deprecated function \e_parse::text_truncate()
defined at /code/e107_handlers/e_parse_class.php:1286
Open
Open
$ttl = $tp->text_truncate($value, $parms['truncate'], '...');
- Exclude checks
Argument 1 (arr1)
is ?array
but \array_merge()
takes array
Open
Open
$options_on = array_merge($options, array('class' => 'e-expandit-on'));
- Exclude checks
Argument 3 (current_value)
is ?''|?false|?int|?string
but \user_class::vetted_tree()
takes int|string
defined at /code/e107_handlers/userclass_class.php:720
Open
Open
$text .= $this->_uc->vetted_tree($name, array($this, '_uc_select_cb'), $current_value, $uc_options, $opt_options)."\n";
- Exclude checks
Argument 4 (showdescription)
is null
but \user_class::uc_checkboxes()
takes bool|false
defined at /code/e107_handlers/userclass_class.php:641
Open
Open
return e107::getUserClass()->uc_checkboxes($name, $curval, $optlist, null,false);
- Exclude checks
Invalid offset "nosort"
of array type array{title:'ID',width:'5%',forced:true}|array{title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass',width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{title:'Options',forced:true,width:'10%',thclass:'center last'}|array{title:'Poll Answers',type:'text',width:'auto',thclass:'left'}|array{title:'Poll Question',width:'auto'}|array{title:'Userclass',type:'text',width:'auto'}|array{title?:null,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}
Open
Open
if ($querypattern != '' && $key !== 'options' && $key !== 'checkboxes' && !vartrue($val['nosort']))
- Exclude checks
Call to deprecated function \getperms()
defined at /code/class2.php:1322
Open
Open
if(deftrue('BOOTSTRAP') && getperms($perms))
- Exclude checks
Call to undeclared method \e_form::options
(Did you mean expr->option()) Open
Open
return $this->options($parms, $value, $id, $attributes);
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$current_fields = varset($options['fieldpref']) ? $options['fieldpref'] : array_keys($options['fields']);
- Exclude checks
Argument 1 (encoded_string)
is array{}
but \parse_str()
takes string
Open
Open
parse_str($data['readParms'], $data['readParms']);
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$text .= vartrue($options['table_post']);
- Exclude checks
Invalid offset "idField"
of array type array{}
Open
Open
$data['readParms']['__idval'] = $fieldvalues[$data['readParms']['idField']];
- Exclude checks
When fetching an array index from a value of type array,
found an array index of type null,
but expected the index to be of the non-nullable type int|string
Open
Open
$data['readParms']['__idval'] = $fieldvalues[$data['readParms']['idField']];
- Exclude checks
Suspicious array access to ?mixed
Open
Open
<form method='post' action='".$url."' id='{$form['id']}-form' enctype='multipart/form-data' autocomplete='off' >
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$legend_class = vartrue($options['legend_class'], 'e-hideme');
- Exclude checks
Suspicious array access to ?mixed
Open
Open
foreach ($form['fieldsets'] as $elid => $data)
- Exclude checks
Invalid offset "toggle"
of array type array{title:'ID',width:'5%',forced:true}|array{title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass',url:string,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass',width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{title:'Options',forced:true,width:'10%',thclass:'center last'}|array{title:'Poll Answers',type:'text',width:'auto',thclass:'left'}|array{title:'Poll Question',width:'auto'}|array{title:'Userclass',type:'text',width:'auto'}|array{title?:null,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{url:string,title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass'|null,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}
Open
Open
$text .= ($key === 'checkboxes') ? $this->checkbox_toggle('e-column-toggle', vartrue($val['toggle'], 'multiselect')) : '';
- Exclude checks
Argument 1 (id)
is string
but \user_class::getName()
takes int
defined at /code/e107_handlers/userclass_class.php:954
Open
Open
$uv[] = $this->_uc->getName($cid);
- Exclude checks
Suspicious array access to \e_admin_tree_model
Open
Open
$tree_model = $tree_models[$fid];
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$val['url'] = null;
- Exclude checks
Call to deprecated function \e_parse::html_truncate()
defined at /code/e107_handlers/e_parse_class.php:1183
Open
Open
$value = $tp->html_truncate($value, $parms['htmltruncate'], '');
- Exclude checks
Invalid offset "title"
of array type array{thumbnail:mixed,label:string}
Open
Open
'title' => varset($val['title']),
- Exclude checks
Argument 4 (options)
is array|array<string>|array{label:'Disabled'|mixed}</string>
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text = $this->radio($name, 1, $checked_enabled, $options_on) . ' ' . $this->radio($name, 0, !$checked_enabled, $options_off);
- Exclude checks
Argument 4 (optlist)
is null
but \user_class::vetted_tree()
takes string
defined at /code/e107_handlers/userclass_class.php:720
Open
Open
$text .= $this->_uc->vetted_tree($name, array($this, '_uc_select_cb'), $current_value, $uc_options, $opt_options)."\n";
- Exclude checks
Invalid offset "noselector"
of array type array{title:'Lang Prefix',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type',url:string,type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lower Threshold',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Image',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Name',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title?:null,type:'text',width:'auto',thclass:'left',class:'left'}|array{url:string,title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type'|null,type:'text',width:'auto',thclass:'left',class:'left'}
Open
Open
$text .= ($key === 'options' && !vartrue($val['noselector'])) ? $this->columnSelector($fieldarray, $columnPref) : '';
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$formPre = vartrue($options['form_pre']);
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$elid = $form['id'].'-'.$elid;
- Exclude checks
Argument 5 (opt_options)
is array{}
but \user_class::vetted_tree()
takes string
defined at /code/e107_handlers/userclass_class.php:720
Open
Open
$text .= $this->_uc->vetted_tree($name, array($this, '_uc_select_cb'), $current_value, $uc_options, $opt_options)."\n";
- Exclude checks
Argument 1 (str)
is int
but \strtolower()
takes string
Open
Open
$name = strtolower($name);
- Exclude checks
Call to deprecated function \e_parse::text_truncate()
defined at /code/e107_handlers/e_parse_class.php:1286
Open
Open
$value = $tp->text_truncate($value, $parms['truncate'], '...');
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$fields = $options['fields'];
- Exclude checks
Suspicious array access to ?mixed
Open
Open
<legend class='{$legend_class}'>".$options['legend']. '</legend>
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$text .= $this->renderTableRow($fields, $current_fields, $model->getData(), $options['pid']);
- Exclude checks
Suspicious array access to ?mixed
Open
Open
' .vartrue($options['fieldset_post']). '
- Exclude checks
Saw unextractable annotation for comment '* @param @forms'
Open
Open
* @param @forms
- Exclude checks
Variable $options_on
was undeclared, but array fields are being added to it. Open
Open
$options_on['label'] = $labels['off'];
- Exclude checks
Argument 4 (options)
is array|array{help:?mixed|?string|mixed}|array{label:mixed}
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text[] = $this->radio($name, $value, (string) $checked === (string) $value, $options);
- Exclude checks
Argument 4 (options)
is array{style:''|'font-weight:bold'|'font-weight:bold; font-style: italic;'}
but \e_form::option()
takes string
defined at /code/e107_handlers/form_handler.php:3604
Open
Open
return $this->option($prefix.$this->_uc->getName($classnum), $classSign.$classIndex, ($current_value !== '' && in_array($classnum, $tmp)), array('style' => ($style)))."\n";
- Exclude checks
Call to undeclared method \e_admin_controller::getTabs
Open
Open
$tabs = $adminUI->getController()->getTabs();
- Exclude checks
Invalid offset "nolist"
of array type array{title:'ID',width:'5%',forced:true}|array{title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass',width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{title:'Options',forced:true,width:'10%',thclass:'center last'}|array{title:'Poll Answers',type:'text',width:'auto',thclass:'left'}|array{title:'Poll Question',width:'auto'}|array{title:'Userclass',type:'text',width:'auto'}|array{title?:null,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}
Open
Open
if ((in_array($key, $columnPref) || ($key === 'options' && isset($val['title'])) || (vartrue($val['forced']))) && !vartrue($val['nolist']))
- Exclude checks
Invalid offset "noselector"
of array type array{title:'ID',width:'5%',forced:true}|array{title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass',url:string,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass',width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{title:'Options',forced:true,width:'10%',thclass:'center last'}|array{title:'Poll Answers',type:'text',width:'auto',thclass:'left'}|array{title:'Poll Question',width:'auto'}|array{title:'Userclass',type:'text',width:'auto'}|array{title?:null,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}|array{url:string,title:'ID'|'Options'|'Poll Answers'|'Poll Question'|'Userclass'|null,width:'10%'|'5%'|'auto',forced:true,type:'text',thclass:'center last'|'left'}
Open
Open
$text .= ($key === 'options' && !vartrue($val['noselector'])) ? $this->columnSelector($fieldarray, $columnPref) : '';
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$data['readParms'] = array();
- Exclude checks
Suspicious array access to nullable ?array{forced:mixed,readParms:array{}}|?array{readParms:array{}}|?mixed
Open
Open
if(vartrue($data['type']) === 'user' /* && isset($data['readParms']['idField'])*/)
- Exclude checks
Invalid offset "nameField"
of array type array{__idval:mixed}|array{}
Open
Open
$data['readParms']['__nameval'] = $fieldvalues[$data['readParms']['nameField']];
- Exclude checks
Call to deprecated function \e_parse::text_truncate()
defined at /code/e107_handlers/e_parse_class.php:1286
Open
Open
$ttl = $tp->text_truncate($value, $parms['truncate'], '...');
- Exclude checks
Suspicious array access to ?mixed
Open
Open
' .vartrue($form['footer']). '
- Exclude checks
Argument 4 (options)
is array|array<string>|array{label:'Disabled'|mixed}</string>
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text = $this->radio($name, 0, !$checked_enabled, $options_off) . ' ' . $this->radio($name, 1, $checked_enabled, $options_on);
- Exclude checks
Argument 2 (str)
is false
but \explode()
takes string
Open
Open
$selected = explode(',', $selected);
- Exclude checks
Argument 4 (options)
is array|array{disabled:bool}
but \e_form::option()
takes string
defined at /code/e107_handlers/form_handler.php:3604
Open
Open
$text .= $this->option($lab, $val, (is_array($selected) ? in_array($val, $selected) : $selected == $val), $opts)."\n";
- Exclude checks
Suspicious array access to nullable ?array{url:null}|?array{url:}|?mixed
Open
Open
$ret .= vartrue($val['text']);
- Exclude checks
Argument 1 (str)
is null
but \strtolower()
takes string
Open
Open
$name = strtolower($name);
- Exclude checks
Invalid offset "toggle"
of array type array{title:'Lang Prefix',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type',url:string,type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lower Threshold',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Image',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Name',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title?:null,type:'text',width:'auto',thclass:'left',class:'left'}|array{url:string,title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type'|null,type:'text',width:'auto',thclass:'left',class:'left'}
Open
Open
$text .= ($key === 'checkboxes') ? $this->checkbox_toggle('e-column-toggle', vartrue($val['toggle'], 'multiselect')) : '';
- Exclude checks
Returning type null
but renderTableCells()
is declared to return string
Open
Open
return null;
- Exclude checks
Argument 2 (str)
is bool|false
but \explode()
takes string
Open
Open
$selected = explode(',', $selected);
- Exclude checks
Argument 2 (callback)
is array{0:\e_form,1:'_uc_select_cb'}
but \user_class::vetted_tree()
takes \function|object|string
defined at /code/e107_handlers/userclass_class.php:720
Open
Open
$text .= $this->_uc->vetted_tree($name, array($this, '_uc_select_cb'), $current_value, $uc_options, $opt_options)."\n";
- Exclude checks
Invalid offset "align"
of array type array{class:mixed}
Open
Open
$align = vartrue($options['align'],'left');
- Exclude checks
Suspicious type null
of a variable or expression used to build a string. (Expected type to be able to cast to a string) Open
Open
$class = vartrue($val['class']) ? 'class="'.$val['class'].'"' : '';
- Exclude checks
Invalid offset "forced"
of array type array{title:'Lang Prefix',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lower Threshold',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Image',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Name',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title?:null,type:'text',width:'auto',thclass:'left',class:'left'}
Open
Open
if ((in_array($key, $columnPref) || ($key === 'options' && isset($val['title'])) || (vartrue($val['forced']))) && !vartrue($val['nolist']))
- Exclude checks
Suspicious array access to ?mixed
Open
Open
$formPost = vartrue($options['form_post']);
- Exclude checks
Invalid offset "class"
of array type array{pk:int,url:mixed|string}|array{url:mixed}|array{url:string}
Open
Open
$class = varset($options['class']);
- Exclude checks
Argument 4 (options)
is array|array<string>|array{label:'Disabled'|mixed}</string>
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text = $this->radio($name, 0, !$checked_enabled, $options_on) . ' ' . $this->radio($name, 1, $checked_enabled, $options_off);
- Exclude checks
Argument 4 (options)
is array|array{help:mixed|string}|array{label:mixed}
but \e_form::radio()
takes null
defined at /code/e107_handlers/form_handler.php:2942
Open
Open
$text[] = $this->radio($name, $value, (string) $checked === (string) $value, $options);
- Exclude checks
Argument 4 (extra_js)
is array|array{options:string}|array{}
but \user_class::uc_dropdown()
takes string
defined at /code/e107_handlers/userclass_class.php:459
Open
Open
return e107::getUserClass()->uc_dropdown($name, $curval, $optlist, $opt);
- Exclude checks
Variable $TEMPLATE
was undeclared, but array fields are being added to it. Open
Open
$TEMPLATE['start'] = '<hr><h4>' .defset('LAN_RELATED', 'Related')."</h4><ul class='e-related'>";
- Exclude checks
When fetching an array index from a value of type string,
found an array index of type 'path',
but expected the index to be of type int
Open
Open
$ival = $value[$i]['path'];
- Exclude checks
Suspicious array access to ?mixed
Open
Open
".vartrue($form['header']). '
- Exclude checks
Argument 2 (curval)
is int
but \user_class::uc_checkboxes()
takes string
defined at /code/e107_handlers/userclass_class.php:641
Open
Open
return e107::getUserClass()->uc_checkboxes($name, $curval, $optlist, null,false);
- Exclude checks
Invalid offset "nosort"
of array type array{title:'Lang Prefix',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lang Prefix'|'Lower Threshold'|'Rank Image'|'Rank Name'|'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Lower Threshold',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Image',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Rank Name',type:'text',width:'auto',thclass:'left',class:'left'}|array{title:'Type',type:'text',width:'auto',thclass:'left',class:'left'}|array{title?:null,type:'text',width:'auto',thclass:'left',class:'left'}
Open
Open
if ($querypattern != '' && $key !== 'options' && $key !== 'checkboxes' && !vartrue($val['nosort']))
- Exclude checks
Suspicious array access to nullable ?array{forced:mixed,readParms:array{}}|?array{readParms:array{}}|?mixed
Open
Open
if(vartrue($data['type']) !== 'method' && empty($data['forced']) && !isset($fieldvalues[$field]) && $fieldvalues[$field] !== null)
- Exclude checks
Returning type null
but renderValue()
is declared to return string
Open
Open
return null;
- Exclude checks
Call to deprecated function \e_parse::html_truncate()
defined at /code/e107_handlers/e_parse_class.php:1183
Open
Open
$value = $tp->html_truncate($value, $parms['htmltruncate']);
- Exclude checks
Call to deprecated function \e_parse::html_truncate()
defined at /code/e107_handlers/e_parse_class.php:1183
Open
Open
$value = $tp->html_truncate($value, $parms['htmltruncate']);
- Exclude checks
When fetching an array index from a value of type string,
found an array index of type 'path',
but expected the index to be of type int
Open
Open
$ival = isset($value[$i]) ? $value[$i]['path'] : '';
- Exclude checks