- missing STATUS
[m6w6/ext-http] / php_http.h
1 /*
2 +----------------------------------------------------------------------+
3 | PECL :: http |
4 +----------------------------------------------------------------------+
5 | This source file is subject to version 3.0 of the PHP license, that |
6 | is bundled with this package in the file LICENSE, and is available |
7 | through the world-wide-web at http://www.php.net/license/3_0.txt. |
8 | If you did not receive a copy of the PHP license and are unable to |
9 | obtain it through the world-wide-web, please send a note to |
10 | license@php.net so we can mail you a copy immediately. |
11 +----------------------------------------------------------------------+
12 | Copyright (c) 2004-2005 Michael Wallner <mike@php.net> |
13 +----------------------------------------------------------------------+
14 */
15
16 /* $Id$ */
17
18 #ifndef PHP_EXT_HTTP_H
19 #define PHP_EXT_HTTP_H
20
21 #define HTTP_PEXT_VERSION "0.8.0-dev"
22
23 /* make compile on Win32 */
24 #ifdef HTTP_HAVE_CURL
25 # ifdef PHP_WIN32
26 # include <winsock2.h>
27 # endif
28 # include <curl/curl.h>
29 #endif
30 #include "ext/standard/md5.h"
31 #include "phpstr/phpstr.h"
32
33 extern zend_module_entry http_module_entry;
34 #define phpext_http_ptr &http_module_entry
35
36 ZEND_BEGIN_MODULE_GLOBALS(http)
37 zend_bool etag_started;
38 PHP_MD5_CTX etag_md5;
39 php_stream_statbuf ssb;
40 char *ctype;
41 char *etag;
42 time_t lmod;
43 char *allowed_methods;
44 char *cache_log;
45
46 #ifdef HTTP_HAVE_CURL
47 # if LIBCURL_VERSION_NUM < 0x070c00
48 char curlerr[CURL_ERROR_SIZE + 1];
49 # endif
50 zend_llist to_free;
51 #endif /* HTTP_HAVE_CURL */
52 ZEND_END_MODULE_GLOBALS(http)
53
54 #ifdef ZTS
55 # include "TSRM.h"
56 # define HTTP_G(v) TSRMG(http_globals_id, zend_http_globals *, v)
57 #else
58 # define HTTP_G(v) (http_globals.v)
59 #endif
60
61 PHP_FUNCTION(http_test);
62 PHP_FUNCTION(http_date);
63 PHP_FUNCTION(http_absolute_uri);
64 PHP_FUNCTION(http_negotiate_language);
65 PHP_FUNCTION(http_negotiate_charset);
66 PHP_FUNCTION(http_redirect);
67 PHP_FUNCTION(http_send_status);
68 PHP_FUNCTION(http_send_last_modified);
69 PHP_FUNCTION(http_send_content_type);
70 PHP_FUNCTION(http_send_content_disposition);
71 PHP_FUNCTION(http_match_modified);
72 PHP_FUNCTION(http_match_etag);
73 PHP_FUNCTION(http_cache_last_modified);
74 PHP_FUNCTION(http_cache_etag);
75 PHP_FUNCTION(http_send_data);
76 PHP_FUNCTION(http_send_file);
77 PHP_FUNCTION(http_send_stream);
78 PHP_FUNCTION(http_chunked_decode);
79 PHP_FUNCTION(http_split_response);
80 PHP_FUNCTION(http_parse_headers);
81 PHP_FUNCTION(http_get_request_headers);
82 #ifdef HTTP_HAVE_CURL
83 PHP_FUNCTION(http_get);
84 PHP_FUNCTION(http_head);
85 PHP_FUNCTION(http_post_data);
86 PHP_FUNCTION(http_post_fields);
87 #endif /* HTTP_HAVE_CURL */
88 PHP_FUNCTION(http_auth_basic);
89 PHP_FUNCTION(http_auth_basic_cb);
90 #ifndef ZEND_ENGINE_2
91 PHP_FUNCTION(http_build_query);
92 #endif /* ZEND_ENGINE_2 */
93 PHP_FUNCTION(ob_etaghandler);
94
95 PHP_MINIT_FUNCTION(http);
96 PHP_MSHUTDOWN_FUNCTION(http);
97 PHP_RINIT_FUNCTION(http);
98 PHP_RSHUTDOWN_FUNCTION(http);
99 PHP_MINFO_FUNCTION(http);
100
101 #endif /* PHP_HTTP_H */
102
103 /*
104 * Local variables:
105 * tab-width: 4
106 * c-basic-offset: 4
107 * End:
108 * vim600: noet sw=4 ts=4 fdm=marker
109 * vim<600: noet sw=4 ts=4
110 */
111