curl_close

Supported Versions: PHP 4 >= 4.0.2, PHP 5, PHP 7, PHP 8
Close a cURL session
curl_close(CurlHandle $handle): void
        $ch curl_init($url);

        
curl_setopt_array($ch$options);

        
curl_exec($ch);

        
curl_close($ch);

        
fclose($fp);

    }
        $ch curl_init($url);

        
curl_setopt_array($ch$options);

        
curl_exec($ch);

        
curl_close($ch);

        
fclose($fp);

    }
        $ch curl_init($url);

        
curl_setopt_array($ch$options);

        
curl_exec($ch);

        
curl_close($ch);

        
fclose($fp);

    }
    private function closeCurlHandleNext(): void

    
{

        if (
$this->curlHandleNext !== null) {

            
curl_close($this->curlHandleNext);

            
$this->curlHandleNext null;

        }

    }
    private function closeCurlHandleResult(): void

    
{

        if (
$this->curlHandleResult !== null) {

            
curl_close($this->curlHandleResult);

            
$this->curlHandleResult null;

        }

    }