Deprecatedfunctions ※posixregex series PHP5.3.0 and later regex. If you want to use the PCRE specification, POSIXRegex is not recommended (Uniform Regex to avoid too many specifications ?). Therefore, the following is a list of functions (POSIX) that are not recommended and recommended to be replaced with PCRE. For details, see PHP: Differen.
Deprecated functions ※posix Regex series PHP 5.3.0 and later regex. If you want to use the PCRE specification, POSIX Regex is not recommended (Uniform Regex to avoid too many specifications ?). Therefore, the following is a list of functions (POSIX) that are not recommended and recommended to be replaced with PCRE. For details, see PHP: Differen.
Deprecated functions
※Posix Regex Series
For regex after PHP 5.3.0, we hope to use the PCRE specification. POSIX Regex is not recommended (Uniform Regex to avoid too many specifications ?).
Therefore, the following is a list of functions (POSIX) that are not recommended and recommended to be replaced with PCRE. For details, see PHP:
Differences from POSIX regex
* POSIX → PCRE
* Ereg_replace () → preg_replace ()
* Ereg () → preg_match ()
* Ereg_replace () → preg_replace ()
* Eregi_replace () → preg_replace ()
This function is case insensitive. Replace it with preg_replace ("/original rule/I ",...);
* Eregi () → preg_match ()
* Split () → preg_split ()
* Spliti () → preg_split ()
* SQL _regcase () → No equivalent
* Split of regex is required, which can be replaced by preg_split ().
* No regex is required. You only need to quickly split a fixed string and replace it with explode (). (The speed is much faster than that of regex)
In addition:
If php5.3 is required, modify the following code in php. ini:
; Extension = php_mbstring.dll to; extension = php_mbstring.dll
; Mbstring. func_overload = 0 to; mbstring. func_overload = 7
Deprecated grammar
※Assigning the return value of new by reference is deprecated in
Solution: After php5.3 starts, the "= &" symbol in php is abolished. to copy the file, use = to reference it directly. The details are as follows:
1. PHP5 object replication adopts the reference method;
2. If the reference method is not used, add the keyword clone when copying the object;
3. If you want to change some attributes during the replication process, add function _ clone ();
Or block errors.