PHPackages                             mogetutu/curl - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [HTTP &amp; Networking](/categories/http)
4. /
5. mogetutu/curl

Abandoned → [guzzle/guzzle](/?search=guzzle%2Fguzzle)ArchivedLibrary[HTTP &amp; Networking](/categories/http)

mogetutu/curl
=============

Simple Curl PHP Helper Library

3316.8k16PHP

Since Apr 8Pushed 11y ago2 watchersCompare

[ Source](https://github.com/mogetutu/simplePHP-curl)[ Packagist](https://packagist.org/packages/mogetutu/curl)[ RSS](/packages/mogetutu-curl/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)DependenciesVersions (1)Used By (0)

Better, well tested and developed cURL Libraries you can use.
-------------------------------------------------------------

[](#better-well-tested-and-developed-curl-libraries-you-can-use)

- [Guzzle](http://guzzlephp.org/)
- [Buzz](https://github.com/kriswallsmith/Buzz)
- [Requests](http://requests.ryanmccue.info/)

Simple PHP-cURL library
=======================

[](#simple-php-curl-library)

Requirements
------------

[](#requirements)

1. PHP 5.1+
2. libcurl

Features
--------

[](#features)

- POST/GET/PUT/DELETE requests over HTTP
- HTTP Authentication
- Follows redirects
- Returns error string
- Provides debug information
- Proxy support
- Cookies

Download
--------

[](#download)

Examples
--------

[](#examples)

```
$curl = New Curl;

```

### Simple calls

[](#simple-calls)

These do it all in one line of code to make life easy. They return the body of the page, or FALSE on fail.

```
// Simple call to remote URL
echo $curl->simple_get('http://example.com/');

// Simple call to CI URI
$curl->simple_post('controller/method', array('foo'=>'bar'));

// Set advanced options in simple calls
// Can use any of these flags http://uk3.php.net/manual/en/function.curl-setopt.php

$curl->simple_get('http://example.com', array(CURLOPT_PORT => 8080));
$curl->simple_post('http://example.com', array('foo'=>'bar'), array(CURLOPT_BUFFERSIZE => 10));

```

### Advanced calls

[](#advanced-calls)

These methods allow you to build a more complex request.

```
// Start session (also wipes existing/previous sessions)
$curl->create('http://example.com/');

// Option & Options
$curl->option(CURLOPT_BUFFERSIZE, 10);
$curl->options(array(CURLOPT_BUFFERSIZE => 10));

// More human looking options
$curl->option('buffersize', 10);

// Login to HTTP user authentication
$curl->httpLogin('username', 'password');

// Post - If you do not use post, it will just run a GET request
$post = array('foo'=>'bar');
$curl->post($post);

// Cookies - If you do not use post, it will just run a GET request
$vars = array('foo'=>'bar');
$curl->setCookies($vars);

// Proxy - Request the page through a proxy server
// Port is optional, defaults to 80
$curl->proxy('http://example.com', 1080);
$curl->proxy('http://example.com');

// Proxy login
$curl->proxyLogin('username', 'password');

// Execute - returns response
echo $curl->execute();

// Debug data ------------------------------------------------

// Errors
$curl->error_code; // int
$curl->error_string;

// Information
$curl->info; // array

```

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity33

Limited adoption so far

Community16

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 89.5% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/83f24ecb0f06cefdea5221e1cb2ede24466e07c1a5e3343299167cbe5969f42f?d=identicon)[mogetutu](/maintainers/mogetutu)

---

Top Contributors

[![mogetutu](https://avatars.githubusercontent.com/u/411754?v=4)](https://github.com/mogetutu "mogetutu (17 commits)")[![conatus](https://avatars.githubusercontent.com/u/317734?v=4)](https://github.com/conatus "conatus (1 commits)")[![jcwatson11](https://avatars.githubusercontent.com/u/2907918?v=4)](https://github.com/jcwatson11 "jcwatson11 (1 commits)")

### Embed Badge

![Health badge](/badges/mogetutu-curl/health.svg)

```
[![Health](https://phpackages.com/badges/mogetutu-curl/health.svg)](https://phpackages.com/packages/mogetutu-curl)
```

###  Alternatives

[friendsofsymfony/rest-bundle

This Bundle provides various tools to rapidly develop RESTful API's with Symfony

2.8k73.3M315](/packages/friendsofsymfony-rest-bundle)[php-http/discovery

Finds and installs PSR-7, PSR-17, PSR-18 and HTTPlug implementations

1.3k309.5M1.2k](/packages/php-http-discovery)[nyholm/psr7

A fast PHP7 implementation of PSR-7

1.3k235.4M2.4k](/packages/nyholm-psr7)[pusher/pusher-php-server

Library for interacting with the Pusher REST API

1.5k94.8M290](/packages/pusher-pusher-php-server)[spatie/crawler

Crawl all internal links found on a website

2.8k16.3M52](/packages/spatie-crawler)[react/http

Event-driven, streaming HTTP client and server implementation for ReactPHP

78126.4M414](/packages/react-http)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
