* fix and adjust code.
This commit is contained in:
@@ -1531,7 +1531,7 @@ class baseRouter
|
||||
foreach($passedParams as $param => $value)
|
||||
{
|
||||
if(preg_match('/[^a-zA-Z0-9_\.]/', $param)) die('Bad Request!');
|
||||
if(preg_match('/[^a-zA-Z0-9=_,`#+\/\.%\|\x7f-\xff]/', trim($value))) die('Bad Request!');
|
||||
if(preg_match('/[^a-zA-Z0-9=_,`#+\^\/\.%\|\x7f-\xff]/', trim($value))) die('Bad Request!');
|
||||
}
|
||||
|
||||
unset($passedParams['onlybody']);
|
||||
|
||||
@@ -297,6 +297,19 @@ class userModel extends model
|
||||
$data[$i]->address = $users->address[$i];
|
||||
$data[$i]->zipcode = $users->zipcode[$i];
|
||||
|
||||
/* Change for append field, such as feedback.*/
|
||||
if(!empty($this->config->user->batchAppendFields))
|
||||
{
|
||||
$appendFields = explode(',', $this->config->user->batchAppendFields);
|
||||
foreach($appendFields as $appendField)
|
||||
{
|
||||
if(empty($appendField)) continue;
|
||||
if(!isset($users->$appendField)) continue;
|
||||
$fieldList = $users->$appendField;
|
||||
$data[$i]->$appendField = $fieldList[$i];
|
||||
}
|
||||
}
|
||||
|
||||
$accounts[$i] = $data[$i]->account;
|
||||
$prev['dept'] = $data[$i]->dept;
|
||||
$prev['role'] = $data[$i]->role;
|
||||
|
||||
Reference in New Issue
Block a user