在使用php7mar检查我们的代码后,报告中有一些条目与以下内容类似:
#### /includes/classes/class.shopdb.php
* funcGetArg
* Line 206: ` $args = func_get_args();`当我检查指定的文件和代码时,我得到的是:
if(func_num_args() > 1) {
$args = func_get_args();
foreach($args as &$item)
$item = ShopDB::quote($item);
$query = vsprintf(str_replace('?', '%s', $query), array_slice($args, 1));
}我真的看不出有什么问题。还有其他人吗?
发布于 2020-08-30 20:48:45
经过一些搜索,func_get_args应该可以在php7中正常工作。在php7mar报告中还有一些我不理解的内容:
return $this->smarty->registered_plugins[$plugin_type][$tag][0][0]->$function[1]($new_args, $this);return $this->default_handler_plugins[$plugin_type][$tag][0][0]->$function[1]($new_args, $this);return $this->smarty->registered_plugins[Smarty::PLUGIN_COMPILER][$tag][0][0]->$function[1]($args, $this);$this->$row[0] = $row[1];* Remember to use ampersand when creating an OLE object ($my_ole =& new OLE();)https://stackoverflow.com/questions/63621427
复制相似问题