[wp-trac] [WordPress Trac] #16855: HTTP API No Follow Redirection

WordPress Trac wp-trac at lists.automattic.com
Mon Mar 14 16:11:13 UTC 2011

#16855: HTTP API No Follow Redirection
 Reporter:  TheDeadMedic  |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  3.1
 Severity:  normal        |   Keywords:
 As highlighted in the following discussions, there's an issue when we
 '''don't''' want to follow redirects. On closer inspection, I believe only
 the cURL component is affected.



 Currently, {{{WP_Http_Curl}}} will throw a {{{WP_Error}}} if a redirection
 header was recieved, and the {{{redirection}}} argument is zero.

   ''Maximum redirects followed (0)''

 The FOLLOWLOCATION option ''must'' be false, otherwise cURL treats the
 result as an error.

 if ( !$r['redirection'] )
     curl_setopt( $handle, CURLOPT_FOLLOWLOCATION, false );

 As I say, as far as I know only cURL component is affected.

Ticket URL: <http://core.trac.wordpress.org/ticket/16855>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software

More information about the wp-trac mailing list