[wp-trac] [WordPress Trac] #4779: Proposal for HTTP POST and REQUEST API

WordPress Trac wp-trac at lists.automattic.com
Mon Aug 20 13:15:40 GMT 2007

#4779: Proposal for HTTP POST and REQUEST API
 Reporter:  darkdragon    |       Owner:  anonymous   
     Type:  enhancement   |      Status:  new         
 Priority:  normal        |   Milestone:  2.4 (future)
Component:  Optimization  |     Version:              
 Severity:  normal        |    Keywords:              
 Given that some hosts are paranoid, it would be a good idea to have a
 failover for fsockopen and/or fopen.

 Given some of my tests and passed experience there are three ways to
 attempt a HTTP call that works on both PHP 4.3+ and PHP 5 and a few more
 ways added to just PHP 5.

  * Curl (if extension loaded)
  * Fopen (if ini_settings allows for this. however, PHP 4 and PHP 5 has an
 extra ini setting for allowing fopen and closing
  * Sockets (fsockopen) (second prefer for PHP 4)
  * Streams (prefer for PHP 5 and PHP 4)
  * HTTP (PHP 5.2) (if exists, and if anyone knows how to use it, then use
 this for PHP 5.2)

 If none of these work, then just spit out some error saying the hosts
 sucks or something.

 '''What about Snoopy?'''

 Snoopy supports two of the five, so either expand upon Snoopy, do proper
 testing and use it instead or just basically hack a few working functions

 I would choose to hack a few functions up, given that it would be probably
 easier to add the remaining three to Snoopy. There should still be a
 function or two for which can be refactored later to use Snoopy.

 '''Something about Tuesday'''

 Matt said something about Tuesday, but I'm unsure how quickly I can get
 this API out by myself... Actually, I kid, should only take about 3 hours,
 tops. Except for HTTP as I have no idea how to work for it.

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

More information about the wp-trac mailing list