There usually should be no reason to change the default value of DB_COLLATE. UTF-8 Unicode Turkish collation define( 'DB_COLLATE', 'utf8_turkish_ci' ) UTF-8 Unicode General collation define( 'DB_COLLATE', 'utf8_general_ci' ) The WordPress default DB_COLLATE value: define( 'DB_COLLATE', '' ) (See also Unicode Character Sets in SQL Manual) An example of when you may need to set ”’DB_COLLATE”’ to one of the UTF-8 values defined in UTF-8 character sets for most Western European languages would be when a different language in which the characters that you entered are not the same as what is being displayed. In most cases, this value should be left blank (null) so the database collation will be automatically assigned by MySQL based on the database character set specified by DB_CHARSET. Database collationĭB_COLLATE was made available to allow designation of the database collation (i.e. Adding DB_CHARSET and DB_COLLATE to the wp-config.php file, for an existing blog, can cause major problems. If DB_CHARSET and DB_COLLATE do not exist in your wp-config.php file, DO NOT add either definition to your wp-config.php file unless you read and understand Converting Database Character Sets. If your blog needs a different character set, please read Character Sets and Collations MySQL Supports for valid DB_CHARSET values. There usually should be no reason to change the default value of DB_CHARSET. This example shows utf8 which is considered the WordPress default value: define( 'DB_CHARSET', 'utf8' ) UTF-8 supports any language, so you typically want to leave DB_CHARSET at utf8 and use the DB_COLLATE value for your language instead. The default value of utf8 ( Unicode UTF-8) is almost always the best option. tis620 for TIS620 Thai) to be used when defining the MySQL database tables. Database character setĭB_CHARSET was made available to allow designation of the database character set (e.g. Replace the text string /var/run/mysqld/mysqld.sock above with the socket or pipe information provided by your host. or define( 'DB_HOST', 'example.tld:/var/run/mysqld/mysqld.sock' ) or define( 'DB_HOST', 'localhost:/var/run/mysqld/mysqld.sock' ) If your host uses Unix sockets or pipes, you’ll need to change the DB_HOST value in the wp-config.php file to reflect the socket or pipe information provided by your host. Replace the number 3307 in either of the code examples above with the port number information provided by your host. If your host uses an alternate port number for your database, you’ll need to change the DB_HOST value in the wp-config.php file to reflect the alternate port provided by your host.įor localhost: define( 'DB_HOST', '127.0.0.1:3307' ) įor specified server: define( 'DB_HOST', ':3307' ) If the install fails, contact your web hosting provider. If you are unsure, try installing with the default value of ‘localhost’ and see if it works. Note: There is a good chance you will NOT have to change it. define( 'DB_HOST', 'MyDatabaseHost' ) // Example MySQL Database host A port number or Unix socket file path may be needed as well. If needed, replace ‘ localhost‘, with the name of your database host (e.g. define( 'DB_PASSWORD', 'MyPassWord' ) // Example MySQL password Set Database Host Replace ‘password_here’, with the your password, e.g. define( 'DB_USER', 'MyUserName' ) // Example MySQL username Set Database Password Replace ‘username_here’, with the name of your username e.g. define( 'DB_NAME', 'MyDatabaseName' ) // Example MySQL database name Set Database User Replace ‘database_name_here’, with the name of your database, e.g. Note: Text inside /* */ are comments, for information purposes only. ** The name of the database for WordPress */ĭefine( 'DB_NAME', 'database_name_here' ) ĭefine( 'DB_PASSWORD', 'password_here' ) ** MySQL settings - You can get this info from your web host ** // The values here are examples to show you what to do. Note: This is an example of a default wp-config-sample.php. Locate the file wp-config-sample.php in the base directory of your WordPress directory and open in a text editor. Important: Never use a word processor like Microsoft Word for editing WordPress files! This file is located in the root of your WordPress file directory and contains your website’s base configuration details, such as database connection information. One of the most important files in your WordPress installation is the wp-config.php file. Disable Plugin and Theme Update and Installation.Disable the Plugin and Theme File Editor.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |