2000-09-20 01:32:27 +08:00
|
|
|
/*
|
|
|
|
+----------------------------------------------------------------------+
|
2014-09-20 00:33:14 +08:00
|
|
|
| PHP Version 7 |
|
2000-09-20 01:32:27 +08:00
|
|
|
+----------------------------------------------------------------------+
|
2015-01-15 23:27:30 +08:00
|
|
|
| Copyright (c) 1997-2015 The PHP Group |
|
2000-09-20 01:32:27 +08:00
|
|
|
+----------------------------------------------------------------------+
|
2006-01-01 20:51:34 +08:00
|
|
|
| This source file is subject to version 3.01 of the PHP license, |
|
2000-09-20 01:32:27 +08:00
|
|
|
| that is bundled with this package in the file LICENSE, and is |
|
2003-06-11 04:04:29 +08:00
|
|
|
| available through the world-wide-web at the following url: |
|
2006-01-01 20:51:34 +08:00
|
|
|
| http://www.php.net/license/3_01.txt |
|
2000-09-20 01:32:27 +08:00
|
|
|
| If you did not receive a copy of the PHP license and are unable to |
|
|
|
|
| obtain it through the world-wide-web, please send a note to |
|
|
|
|
| license@php.net so we can mail you a copy immediately. |
|
|
|
|
+----------------------------------------------------------------------+
|
2002-02-28 16:29:35 +08:00
|
|
|
| Author: Sascha Schumann <sascha@schumann.cx> |
|
2000-09-20 01:32:27 +08:00
|
|
|
+----------------------------------------------------------------------+
|
|
|
|
*/
|
|
|
|
|
2005-01-10 23:20:53 +08:00
|
|
|
/* $Id$ */
|
|
|
|
|
2000-09-20 01:32:27 +08:00
|
|
|
#ifndef URL_SCANNER_EX_H
|
|
|
|
#define URL_SCANNER_EX_H
|
|
|
|
|
2000-10-17 01:25:36 +08:00
|
|
|
PHP_MINIT_FUNCTION(url_scanner_ex);
|
|
|
|
PHP_MSHUTDOWN_FUNCTION(url_scanner_ex);
|
2000-09-20 01:32:27 +08:00
|
|
|
|
2002-05-03 16:00:41 +08:00
|
|
|
PHP_RINIT_FUNCTION(url_scanner_ex);
|
|
|
|
PHP_RSHUTDOWN_FUNCTION(url_scanner_ex);
|
2000-09-20 01:32:27 +08:00
|
|
|
|
2015-02-02 11:53:41 +08:00
|
|
|
PHPAPI char *php_url_scanner_adapt_single_url(const char *url, size_t urllen, const char *name, const char *value, size_t *newlen, int urlencode);
|
2014-12-14 06:06:14 +08:00
|
|
|
PHPAPI int php_url_scanner_add_var(char *name, size_t name_len, char *value, size_t value_len, int urlencode);
|
|
|
|
PHPAPI int php_url_scanner_reset_vars(void);
|
2001-07-04 23:30:21 +08:00
|
|
|
|
2014-09-21 04:42:02 +08:00
|
|
|
#include "zend_smart_str_public.h"
|
2000-09-20 09:15:10 +08:00
|
|
|
|
2000-09-20 01:32:27 +08:00
|
|
|
typedef struct {
|
2000-09-20 09:15:10 +08:00
|
|
|
/* Used by the mainloop of the scanner */
|
|
|
|
smart_str tag; /* read only */
|
|
|
|
smart_str arg; /* read only */
|
2000-09-20 16:06:01 +08:00
|
|
|
smart_str val; /* read only */
|
2000-09-20 09:15:10 +08:00
|
|
|
smart_str buf;
|
|
|
|
|
|
|
|
/* The result buffer */
|
2000-09-20 01:32:27 +08:00
|
|
|
smart_str result;
|
2000-09-20 09:15:10 +08:00
|
|
|
|
2002-05-05 02:33:13 +08:00
|
|
|
/* The data which is appended to each relative URL/FORM */
|
|
|
|
smart_str form_app, url_app;
|
2002-05-03 16:00:41 +08:00
|
|
|
|
|
|
|
int active;
|
2000-09-20 09:15:10 +08:00
|
|
|
|
2000-10-17 01:25:36 +08:00
|
|
|
char *lookup_data;
|
2000-09-20 01:32:27 +08:00
|
|
|
int state;
|
2015-01-03 17:22:58 +08:00
|
|
|
|
2000-10-17 01:25:36 +08:00
|
|
|
/* Everything above is zeroed in RINIT */
|
|
|
|
HashTable *tags;
|
2000-09-20 01:32:27 +08:00
|
|
|
} url_adapt_state_ex_t;
|
|
|
|
|
|
|
|
#endif
|