HTTP Class (supports both cURL and fsockopen) - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: HTTP Class (supports both cURL and fsockopen) (/showthread.php?tid=5386) |
HTTP Class (supports both cURL and fsockopen) - El Forum - 01-20-2008 [eluser]PHP Four[/eluser] Hi Folks, I've released a HTTP class today in my blog that can be used in CodeIgniter (I use in my projcts!) for all kinds of resource fetching from the web. It's a wrapper HTTP class that uses either cURL or fsockopen (degrades to fsockopen if cURL is not loaded in php). Features include: * Can use both cURL and fsockopen. * Degrades to fsockopen if cURL not enabled. * Supports HTTP Basic authentication. * Supports defining custom request headers. * Supports defining connection timeout values. * Supports defining user agent and referral values. * Supports both user-defined and persistent cookies. * Supports secure connections (HTTPS) with and without cURL. * Supports adding requests parameters for both GET and POST. * Supports automatic redirection (maximum redirect can be defined). * Returns HTTP response headers and response body data separately. Check it out here: HTTP Class Thanks Md Emran Hasan |