Skip to content

httpClient doesn't allow to change the curl_setopt options #37798

@dvdknaap

Description

@dvdknaap

Description
It would be nice if you could change the curl_setopt option to what every like you want at the moment it's not possible to change any and it's only using the defined ones.

Could there be a function or option param that will be used to change the curl to your liking ?

Example

        $options = [
            'curlOptions' => [
                'CURLOPT_IPRESOLVE' => CURL_IPRESOLVE_V4,
            ],
        ];

            /** @var CurlResponse $res */
            $res = $httpClient->request(
                $method,
                $requestUrl,
                $options
            );


# Then when executing `vendor/symfony/http-client/AmpHttpClient.php` check for this option 'curlOptions' and pass it in curl_setopt_array

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions