From ac38b635cb83304566b31901cf4aa95bd108d941 Mon Sep 17 00:00:00 2001 From: Scott MacVicar Date: Mon, 14 May 2007 17:10:47 +0000 Subject: Add mysql_set_charset() so that the connection encoding can be changed. This is similar to the SET NAMES statement but allows the mysql_real_escape_string to use the correct character set. --- ext/mysql/php_mysql.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'ext/mysql/php_mysql.h') diff --git a/ext/mysql/php_mysql.h b/ext/mysql/php_mysql.h index 11d5d8295c..a088208a4b 100644 --- a/ext/mysql/php_mysql.h +++ b/ext/mysql/php_mysql.h @@ -91,6 +91,9 @@ PHP_FUNCTION(mysql_stat); PHP_FUNCTION(mysql_thread_id); PHP_FUNCTION(mysql_client_encoding); PHP_FUNCTION(mysql_ping); +#if (MYSQL_VERSION_ID >= 40113 && MYSQL_VERSION_ID < 50000) || MYSQL_VERSION_ID >= 50007 +PHP_FUNCTION(mysql_set_charset); +#endif ZEND_BEGIN_MODULE_GLOBALS(mysql) long default_link; -- cgit v1.2.1