Commit Graph

173 Commits

Author SHA1 Message Date
Sascha Schumann
a1b42e3f5e first import of session module 1999-06-05 19:52:58 +00:00
Zeev Suraski
e586468a4e Not sure that's the right fix, but at least it fixes the symptom 1999-06-05 13:56:18 +00:00
Andrey Hristov
dbfeaabb16 Added preg_quote() function. 1999-06-04 13:56:23 +00:00
Andrey Hristov
c7a606c4a3 *** empty log message *** 1999-06-04 13:37:44 +00:00
Zeev Suraski
1ecca4b8e8 Fix UNIX MySQL build 1999-06-04 12:51:41 +00:00
Zeev Suraski
3cad348509 * Add a new workspace for dynamic PHP extensions.
* Add a few functions to PHP's API.
* Get the MySQL extension up-to-date and thread safe.
* Add a project for building the MySQL extension under Win32.
1999-06-04 10:45:54 +00:00
Andrey Hristov
0f99eeb29f function dir doesn't exist anymore 1999-06-01 21:01:02 +00:00
Andrey Hristov
aea7498779 *** empty log message *** 1999-06-01 20:31:39 +00:00
Andi Gutmans
250d803c31 - Fix for exec to use API 1999-06-01 16:41:56 +00:00
Andi Gutmans
f153896de5 *** empty log message *** 1999-05-31 17:41:41 +00:00
Andrey Hristov
aba3ea97cd preg_match_all() now returns the number of global matches. 1999-05-30 14:48:39 +00:00
Sascha Schumann
577340bb9f zend_hash_merge was changed 1999-05-30 11:57:28 +00:00
Andrey Hristov
a88b37788e Updated preg_split(). 1999-05-29 20:45:00 +00:00
Andrey Hristov
70dc46892a Fix preg_match_all to do proper matching with \b. 1999-05-29 20:04:05 +00:00
Andrey Hristov
9c970e1910 Fixed PCRE so that global matching with patterns with \b works. 1999-05-29 19:38:50 +00:00
Zeev Suraski
274f3aa727 Fix 1999-05-29 18:28:46 +00:00
Sascha Schumann
03d2a11e27 more VPATH work 1999-05-29 18:11:49 +00:00
Sascha Schumann
b219d491b9 . 1999-05-29 12:15:04 +00:00
Zeev Suraski
0eb1498fa8 * Get Apache module to compile again with the regex stuff.
* Get Apache to propertly work with POST, and some SAPI fixes
1999-05-28 22:41:48 +00:00
Sascha Schumann
dfce358a5b that seems to fix it 1999-05-28 21:41:17 +00:00
Sascha Schumann
7401ef12fb Either I'm playing the EG(symbol_table) game wrong or var.c leaks memory
when unserializing arrays/objects. Still testing
1999-05-28 21:27:19 +00:00
Andrey Hristov
3fe94e5b37 -Modified PCRE library slightly to do what needs to be done
-Updated preg_replace() code to handle stuff properly
-Removed ability to specify external PCRE library source to link against
(since our bundled version is patched now)
1999-05-28 20:54:52 +00:00
Zeev Suraski
cd789db6f2 *** empty log message *** 1999-05-28 13:28:50 +00:00
Zeev Suraski
7a167cd0c1 * Use new Zend macros for standardized definition of classes.
* Reverse bogus shutdown order.
* Use the new object/class support of Zend to make the dir functions work again.
1999-05-28 11:09:39 +00:00
Andrey Hristov
a5138d2724 We don't need those there. 1999-05-27 14:02:29 +00:00
Andrey Hristov
e10e4dbe10 Really fix the configuration now so that it's possible to compile both
against the bundled PCRE library and the one external to the source tree.
Crossing my fingers while Zeev compiles this. :)
1999-05-27 13:59:39 +00:00
Sascha Schumann
5d0a7599a9 - fix CGI build (at least) 1999-05-27 01:34:18 +00:00
Zeev Suraski
36947fc45a Fix pcre build 1999-05-27 01:19:00 +00:00
Andrey Hristov
66f850e5b7 -Added PCRE library source
-Updated configuration process
1999-05-26 21:47:57 +00:00
Andrey Hristov
d73c638526 Added preg_split. Same syntax as regular split(). 1999-05-26 18:59:04 +00:00
Andrey Hristov
ff29e85724 Fixing a couple of long standing bugs. 1999-05-26 18:45:53 +00:00
Andrey Hristov
0062ae6218 A few changes here.
First of all, as per extensive discussion on the list, the functions are now
prefixed with "preg" instead of "pcre".

Secondly, global matching is now possible using preg_match_all.  Please, give
suggestions on a better name if this one doesn't sit well with you.  Possible
names are preg_global_match and preg_gmatch.

preg_match_all takes 4 arguments: a regex pattern, a subject string,
the array for capturing subpatterns, and a parameter that tells how the results
in the subpatterns array are arranged.

Basically, preg_match_all will go through the subject string and try to capture
all the matches that it finds, not just the first one like preg_match.

4th parameter can be PREG_PATTERN_ORDER (default) or PREG_SET_ORDER.

Example:
preg_match_all("|</?([^>]+)>|", "<div align=left>a test</div>", $out, PREG_PATTERN_ORDER);

This returns results so that $out[0] is an array of full pattern matches, $out[1] is an array
of first captured subpattern matches, and so on.

$out[0] -> ("<div align=left>", "</div>")
$out[1] -> ("div align=left", "div")

Example:
preg_match_all("|</?([^>]+)>|", "<div align=left>a test</div>", $out, PREG_SET_ORDER);

This returns results so that $out[0] is an array of first full pattern match and subpatterns,
$out[1] is an array of second full pattern match and subpatterns.

$out[0] -> ("<div align=left>", "div align=left")
$out[1] -> ("</div>", "div")

If anyone has a better name for these PREG_ constants and also which one should be the default,
I'd like to hear it.
1999-05-26 15:22:02 +00:00
Andrey Hristov
6155d91e7a Just a little sanity check. 1999-05-25 21:47:58 +00:00
Zeev Suraski
0eb500cef5 Thou shalt use the API, and thou shalt be safe 1999-05-23 20:32:19 +00:00
Andrey Hristov
57b22c8b64 Some comments. 1999-05-22 19:46:27 +00:00
Andrey Hristov
912f17d278 Added ability to pass array parameters to pcre_replace. 1999-05-22 19:14:57 +00:00
Sascha Schumann
13c3c4012e fix compile issues in LDAP/XML exts 1999-05-22 16:12:09 +00:00
Zeev Suraski
a08e3925b1 Time to rename the child 1999-05-22 09:24:21 +00:00
Sascha Schumann
00cb03bd49 add support for mhash 0.5.0
see http://sasweb.de/mhash/
1999-05-21 20:09:23 +00:00
Andrey Hristov
e3a70c1f04 -Added regex cache
-Made module thread-safe
1999-05-21 19:27:44 +00:00
Andrey Hristov
be9dc58cfe Get rid of debug printf's. 1999-05-21 13:29:05 +00:00
Andrey Hristov
17bbbf2963 Initial check-in of PCRE (Perl Compatible Regular Expressions) extension.
PCRE library can be found at ftp://ftp.cus.cam.ac.uk/pub/software/programs/pcre/

config.m4 will be updated to be more robust later on.

perl_match() takes a regular expression, the source string, and the array
for subpattern matches.

perl_replace() takes a regular expression, the search string, and the replacement
string.

Regular expression is specified using delimiters and options.  Example:

perl_match("/<[a-z]*>/i", $text, $tags);

More stuff is coming soon.
1999-05-21 13:17:23 +00:00
Sascha Schumann
b57dc27595 - run ext sources through conv_proto
- add necessary phpext_*_ptr
1999-05-21 10:06:25 +00:00
Sascha Schumann
4fe8fe715e merge in some PHP3 stuff 1999-05-21 08:37:48 +00:00
Sascha Schumann
6f06b11679 incorporate YP/NIS support 1999-05-21 08:29:51 +00:00
Sascha Schumann
fb407676a2 - fix compile issues for various packages (dbase, sysv*, zlib)
- some cleanup in mhash/mcrypt
1999-05-21 08:20:13 +00:00
Sascha Schumann
0fe7fe30b5 - add phpext_pgsql_ptr
- semaphore update for glibc-2.1 systems
1999-05-21 08:04:38 +00:00
Sascha Schumann
672e38da93 Add default path for binary mysql distributions 1999-05-21 07:52:12 +00:00
Sascha Schumann
286fef1ce4 remove debug messages 1999-05-21 07:04:48 +00:00
Sascha Schumann
27fc61c4dc Apply the fix for feof() 1999-05-20 13:56:19 +00:00