Skip to content

HTTP Head Request not working #98

@bytefreak

Description

@bytefreak

Hi,

i have an issue sending http head requests. these will hang indefinitely, because there is no default timeout set. i found the solution: if you want to send a head request with curl, you need to set CURLOPT_NOBODY to true.

so i changed:

curl_setopt($ch, CURLOPT_CUSTOMREQUEST, $this->method);
if ($this->method==HTTP::HEAD) {
curl_setopt($ch, CURLOPT_NOBODY, true);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions