Due to the recent bugs in PHP 5.3.9 (CVE-2012-0830) and prior version (CVE-2011-4885), it is highly recommended to upgrade your PHP interpreter from previous version to the latest stable version (at the time of this writing, the current stable PHP version is 5.3.10). The PHP 5.3.x offers better performance, security patches, and also several deprecated features. Unfortunately, the deprecated features producing some issues for any applications coded with old PHP version. This issues make your application crashed, throwing an error, and may be completely doesn’t work anymore.
To overcome this problem, we recommend you to update your code with the latest PHP functions. Here are the complete list of deprecated PHP features and functions in PHP 5.3.x. We hope this PHP deprecated features and functions cheat list useful for you.
Deprecated –> function / feature will be completely deleted and not worked for PHP next version.
PHP 5.3.0 introduces two new error levels: E_DEPRECATED and E_USER_DEPRECATED. The E_DEPRECATED error level is used to indicate that a function or feature has been deprecated. The E_USER_DEPRECATED level is intended for indicating deprecated features in user code, similarly to the E_USER_ERROR and E_USER_WARNING levels.
The following is a list of deprecated INI directives. Use of any of these INI directives will cause an E_DEPRECATED error to be thrown at startup.
- Comments starting with ‘#’ are now deprecated in .INI files.
- call_user_method() (use call_user_func() instead)
- call_user_method_array() (use call_user_func_array() instead)
- ereg() (use preg_match() instead)
- ereg_replace() (use preg_replace() instead)
- eregi() (use preg_match() with the ‘i’ modifier instead)
- eregi_replace() (use preg_replace() with the ‘i’ modifier instead)
- set_magic_quotes_runtime() and its alias, magic_quotes_runtime()
- session_register() (use the $_SESSION superglobal instead)
- session_unregister() (use the $_SESSION superglobal instead)
- session_is_registered() (use the $_SESSION superglobal instead)
- set_socket_blocking() (use stream_set_blocking() instead)
- split() (use preg_split() instead)
- spliti() (use preg_split() with the ‘i’ modifier instead)
- mysql_db_query() (use mysql_select_db() and mysql_query() instead)
- mysql_escape_string() (use mysql_real_escape_string() instead)
- Passing locale category names as strings is now deprecated. Use the LC_* family of constants instead.
- The is_dst parameter to mktime(). Use the new timezone handling functions instead.
- Assigning the return value of new by reference is now deprecated.
- Call-time pass-by-reference is now deprecated.
Source PHP Deprecated Features (in 5.3.x).
User Related Search
- Deprecated: mysql_escape_string(): This function is deprecated; use mysql_real_escape_string() instead