请问我哪里有错...“处理请求时出错”

问题描述

我尝试回显每个部分的答复,只有最后一部分给出了错误...我仍然无法检测到错误是什么...我感到困惑。

<?PHP // This initialises the Accesstoken

    if(isset($_POST['submit'])){
    
    $cm = curl_init();
    curl_setopt($cm,CURLOPT_URL,"https://sandBox.monnify.com/api/v1/auth/login/");
    curl_setopt($cm,CURLOPT_RETURNTRANSFER,TRUE);
    curl_setopt($cm,CURLOPT_HEADER,FALSE);
    curl_setopt($cm,CURLOPT_POST,CURLOPT_HTTPHEADER,array(
    "Content-Type: application/json","Authorization: Basic TUtfVEVTVF9TQUY3SFI1RjNGOjRTWTZUTkw4Q0szVlBSU0JUSFRSRzJOOFhYRUdDNk5M"
    ));
    
    $response = curl_exec($cm);
    $set = json_decode($response,true);
    $uv = $set['responseBody'];
    $uf = $uv['accesstoken'];   
    curl_close($cm);
    
    // This is for the marking up of responses
    
    $myheaders = array(
    "Authorization:" . "Bearer" . $uf,);
    
    $logged = wp_get_current_user();
    $account = "BizNG - " . $logged->user_login;
    $code = "4934121686";
    $currency = "NGN";
    $vurl = "https://sandBox.monnify.com/api/v1/bank-transfer/reserved-accounts";
    $auth_data = array(
    'accountName' => "BizNG" . $logged->user_login,'accountReference' => $logged->user_login,'currencyCode' => 'NGN','contractCode' => $code,'customerName' => "BizNG" . $logged->user_login,'customerEmail' => 'johnd@jd.33mail.com',);
    
    // This is for the reserved account display
    
    $cv = curl_init();
    curl_setopt($cv,TRUE);
    curl_setopt($cv,FALSE);
    curl_setopt($cv,CURLOPT_POSTFIELDS,$auth_data); 
    curl_setopt($cv,$vurl);
    curl_setopt($cv,$myheaders);
    $reply = curl_exec($cv);
        echo $reply;
    curl_close($cv);
        var_dump($reply);
    
    }
    ?>
     <form method="post"><input type="submit" name="submit" value="submit"/> </form>

请问我哪里出错了?我仍然不断收到此错误

“处理请求时出错,请稍后重试...

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)