Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $curl = curl_init();
- curl_setopt_array($curl, array(
- CURLOPT_URL => "https://idol.infinite-erp.co.id/infinite/org.openbravo.service.json.jsonrest/Locator",
- CURLOPT_RETURNTRANSFER => true,
- CURLOPT_ENCODING => "",
- CURLOPT_MAXREDIRS => 10,
- CURLOPT_TIMEOUT => 300,
- CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
- CURLOPT_CUSTOMREQUEST => "PUT",
- CURLOPT_POSTFIELDS => $orderHeaderUpdateJson,
- CURLOPT_HTTPHEADER => array(
- 'Content-Type:application/json',
- 'Authorization: Basic '. 'YWRtaW4tZmFkb',
- ),
- ));
- $response = curl_exec($curl);
- $err = curl_error($curl);
- curl_close($curl);
- if ($err) {
- echo "cURL Error #:" . $err;
- } else {
- $hasilKembali = json_decode($response);
- }
Add Comment
Please, Sign In to add comment