注册

lang.IllegalArgumentException\",\"error_description\":\"oldPassword is required\"}","status":0}

服务器不是不要原密码么 为啥总是提示需要原密码lang.IllegalArgumentException\",\"error_description\":\"oldPassword is required\"}","status":0} 
 
 
    重置用户密码
    */
    function resetPassword($username,$newpassword){
        //$url=$this->url.'users/'.$username.'/password';
        $url = $this->url . "users/" . $username . "/password";
        $access_token = $this->getToken ();
        
        $options=array(
            "newpassword"=>$newpassword
        );
        $body=json_encode($options);
        //$header=array($this->getToken());
        $header [] = 'Authorization: Bearer ' . $access_token;
        $result=$this->postCurl($url,$options,$header,$type = 'PUT');
        return $result;
    }
    
已邀请:
检查看看是put请求吗

要回复问题请先登录注册