OpenBiblio: Difference between revisions

Jump to navigation Jump to search
1,422 bytes added ,  2 January 2019
m
Text replacement - "in Chinese" to "in Mandarin Chinese"
m (3個修訂)
m (Text replacement - "in Chinese" to "in Mandarin Chinese")
 
(16 intermediate revisions by 4 users not shown)
Line 7: Line 7:
* Setup the MySQL: {openbiblio}/database_constants.php
* Setup the MySQL: {openbiblio}/database_constants.php
: more on [http://www.iriti.cnr.it/openbiblio/install_instructions.html OpenBiblio Install Instructions]
: more on [http://www.iriti.cnr.it/openbiblio/install_instructions.html OpenBiblio Install Instructions]
* run the  http://localhost/openbiblio/install/index.php
* run the  <nowiki>http://localhost/openbiblio/install/index.php</nowiki>


== localization ==
== localization ==
Line 44: Line 44:
     '''$rc = Query::act( 'SET NAMES UTF8' );'''
     '''$rc = Query::act( 'SET NAMES UTF8' );'''
     return $e;
     return $e;
  }
; Modify PHP source (version 0.6.1)
openbiblio\classes\Query.php
add the two lines: '''mysql_query("SET CHARACTER SET utf8");''' and '''mysql_query("SET NAMES utf8");'''
so that all connection will be UTF8
  function _connect_e() {
    static $link;
    if (!isset($link)) {
      if (!function_exists('mysql_connect')) {
        return array(NULL, new DbError("Checking for MySQL Extension...",
                          "Unable to connect to database.",
                          "The MySQL extension is not available"));
      }
      $link = mysql_connect(OBIB_HOST,OBIB_USERNAME,OBIB_PWD);
      mysql_query("SET CHARACTER SET utf8");
      mysql_query("SET NAMES utf8");
      if (!$link) {
        return array(NULL, new DbError("Connecting to database server...",
                                      "Cannot connect to database server.",
                                      mysql_error()));
      }
      $rc = mysql_select_db(OBIB_DATABASE, $link);
      if (!$rc) {
        return array(NULL, new DbError("Selecting database...",
                                      "Cannot select database.",
                                      mysql_error($link)));
      }
    }
    return array($link, NULL);
   }
   }


Line 49: Line 83:
; Validation
; Validation
* click the ''Cataloging'' label -> ''New Bibliography''
* click the ''Cataloging'' label -> ''New Bibliography''
* ''add a new Bibliography'' in Chinese
* ''add a new Bibliography'' in Mandarin Chinese
* & search ''Bibliography Search'' in Chinese
* & search ''Bibliography Search'' in Mandarin Chinese
* Check MySQL DB table biblio, to see if the string store in Chinese. You can use freeware Toad for MySQL to do it.
* Check MySQL DB table biblio, to see if the string stored in Mandarin Chinese. You can use freeware Toad for MySQL to do it.
* Try again in Simplified Chinese
* Try again in Simplified Chinese


Line 58: Line 92:
* [http://obiblio.sourceforge.net/index.php/Main/TranslatingOpenBiblio OpenBiblio | Main / TranslatingOpenBiblio browse]
* [http://obiblio.sourceforge.net/index.php/Main/TranslatingOpenBiblio OpenBiblio | Main / TranslatingOpenBiblio browse]


discussion
* [http://sourceforge.net/p/obiblio/discussion/164978/thread/c04da600/ OpenBiblio / Discussion / Help:0.7.1 default language] 2013-06-30


[[Category:OSS]] [[Category:Education]]
[[Category:OSS]] [[Category:Education]]

Navigation menu