[PHP] cURL 사용해서 post 데이터 넘겨주기
카테고리: PHP
소스 코드 $clientID = "Client ID"; $clientSecret = "Client SecretKey"; $url = "https://www.example.com"; $body = array("foo" => "test", "bar" => "test"); # type1 $body = "foo=test&bar=test"; # type2 $ch = curl_init(); //curl 초기화 curl_setopt_array($ch, array( CURLOPT_URL => $url, //URL 지정하기 CURLOPT_PO