Permalink
Browse files

strange curl bug on customrequest for HEAD http request

  • Loading branch information...
Neo Futur
Neo Futur committed May 19, 2012
1 parent 3e8ac3c commit 8f2eab27c4aea8b0ca5f70f351605bc3c52fb847
Showing with 3 additions and 1 deletion.
  1. +3 −1 inc/Casimir.php
View
@@ -322,7 +322,9 @@ function GetUrlHttpHead( $longurl ){
// Only calling the head
curl_setopt($ch, CURLOPT_HEADER, true); // header will be at output
- curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'HEAD'); // HTTP request is 'HEAD'

This comment has been minimized.

Show comment Hide comment
@neofutur

neofutur May 19, 2012

Owner

debian only bug :p

@neofutur

neofutur May 19, 2012

Owner

debian only bug :p

+ //curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'HEAD'); // HTTP request is 'HEAD'
+ curl_setopt($ch, CURLOPT_NOBODY, true);
+ curl_setopt ($ch, CURLOPT_FOLLOWLOCATION, true);
$content = curl_exec ($ch);
curl_close ($ch);

2 comments on commit 8f2eab2

@neofutur

This comment has been minimized.

Show comment Hide comment
@neofutur

neofutur May 19, 2012

Owner

thank you Someguy123 for allowing me to debug this on your debian server, the bug was not appearing on my gentoo install

Owner

neofutur replied May 19, 2012

thank you Someguy123 for allowing me to debug this on your debian server, the bug was not appearing on my gentoo install

@Someguy123

This comment has been minimized.

Show comment Hide comment
@Someguy123

Someguy123 May 19, 2012

Thanks :)

Thanks :)

Please sign in to comment.