• R/O
  • HTTP
  • SSH
  • HTTPS

nucleus-jp-ancient: Commit

Nucleus CMS日本語版SVNをgit-svnしたもの。リポジトリの変換作業用


Commit MetaInfo

Revision39cd2f1ebf3e5ac6e39a9838eeb0f2c42ca0f721 (tree)
Zeit2011-01-28 23:30:44
Autorsakamocchi <sakamocchi@1ca2...>
Commitersakamocchi

Log Message

There are some servers which install php 5.2.3 but the function mysql_set_charset cannot be used, refering to http://japan.nucleuscms.org/bb/viewtopic.php?p=26641.

git-svn-id: https://svn.sourceforge.jp/svnroot/nucleus-jp/nucleus-jp/tags/release-3-51@1120 1ca29b6e-896d-4ea0-84a5-967f57386b96

Ändern Zusammenfassung

Diff

--- a/utf8/install/index.php
+++ b/utf8/install/index.php
@@ -595,18 +595,16 @@ function doInstall() {
595595 if ($MYSQL_CONN == false) {
596596 _doError(_ERROR15 . ': ' . sql_error() );
597597 }
598-
599-// <add for garble measure>
598+
600599 // 2-2. set DEFAULT CHARSET and COLLATE
601600 $mySqlVer = implode('.', array_map('intval', explode('.', sql_get_server_info($MYSQL_CONN))));
602- if ($mySqlVer >= '5.0.7' && phpversion() >= '5.2.3') {
601+ if ($mySqlVer >= '5.0.7' && function_exists('mysql_set_charset')) {
603602 mysql_set_charset($charset);
604603 } elseif ($mySqlVer >= '4.1.0') {
605604 sql_query("SET NAMES " . $charset);
606605 }
607606 $collation = ($charset == 'utf8') ? 'utf8_unicode_ci' : 'ujis_japanese_ci';
608-// </add for garble measure>*/
609-
607+
610608 // 3. try to create database (if needed)
611609 if ($mysql_create == 1) {
612610 $sql = 'CREATE DATABASE '
Show on old repository browser