Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Some helpers for http connections via PHP.
PHP
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
README.textile
auth_example.php
class.HTTP_Auth.php
class.HTTP_Response.php
license.txt

README.textile

License

Author: Thomas Scholz aka toscho

This work is licensed under the GPL.

Usage

Currently, there are two classes in this package, HTTP_Response and HTTP_Auth.

HTTP_Response

This class handles general HTTP responses: MIME types, client caches, redirects and gzip compression.
There’s also support for Content Negotiation but I recommend to avoid the efforts and send just text/html to everyone.

To send text/html;charset=utf-8 just use:

new HTTP_Response;

That’s it. HTTP_Response will compress the output on demand and set an expiration date based on the age of the last modified file from all your includes.

Further instructions are on my todo list …

HTTP_Auth

This class handles Basic Authentication in UTF-8. See auth_example.php for usage.

Todo

My plan is to make my class HTTP_Negotiate public. If you find any bugs or if you have some hints feel free to use the Issue Tracker.

Something went wrong with that request. Please try again.