WordPress: Answers-Installation:修订间差异

来自站长百科
跳转至: 导航、​ 搜索
(新页面: <div style="border:1px solid blue; background: #CCFFE6; padding:10px; margin:10px; font-size:130%"> These FAQs have been deprecated. You will find the new updated '''Frequently Asked Ques...)
 
无编辑摘要
 
第1行: 第1行:
<div style="border:1px solid blue; background: #CCFFE6; padding:10px; margin:10px; font-size:130%">
<div style="border:1px solid blue; background: #CCFFE6; padding:10px; margin:10px; font-size:130%">
<div style="border:1px solid blue; background: #CCFFE6; padding:10px; margin:10px; font-size:130%">
These FAQs have been deprecated. You will find the new updated '''Frequently Asked Questions''' on the new pages for the [[WordPress:FAQ]].
These FAQs have been deprecated. You will find the new updated '''Frequently Asked Questions''' on the new pages for the [[WordPress:FAQ]].
</div>
这些常见问题解答已经取消了。你在[[WordPress:FAQ|常见问题解答]]的新的页面上会看到新的已更新的'''常见问题解答'''。
</div>
</div>


[[WordPress:FAQ|Back to FAQ]]
[[WordPress:FAQ|Back to FAQ]]
[[WordPress:FAQ|返回到常见问题解答]]
== PHP and MySQL Requirements ==
== PHP and MySQL Requirements ==
== PHP 和MySQL 要求 ==
You certainly need PHP (version 4.1 or newer) and MySQL (version 3.23.23 or newer) to power your WordPress blog. PHP is the scripting language that drives all of WordPress, and without PHP, your server will not be able to interpret the pages that create your weblog. MySQL is a relational database, and WordPress works '''only''' with MySQL. Other databases are not supported at the moment.
You certainly need PHP (version 4.1 or newer) and MySQL (version 3.23.23 or newer) to power your WordPress blog. PHP is the scripting language that drives all of WordPress, and without PHP, your server will not be able to interpret the pages that create your weblog. MySQL is a relational database, and WordPress works '''only''' with MySQL. Other databases are not supported at the moment.


你当然需要PHP(4.1版本或者更新)和MySQL(3.23.23版本或者更新)支持你的WordPress博客。PHP是种脚本语言,运行WordPress的所有部分,如果没有PHP,你的服务器就不能够翻译创建你的博客的页面。MySQL是关系数据库,而且WordPress'''只'''与MySQL一起运行。暂时不支持其它的数据库。
== MySQL 4.1.7 ==


== MySQL 4.1.7 ==
== MySQL 4.1.7 ==


Do NOT use this version of mysql if you are trying to get WordPress installed using a Windows platform. Read this post originally made to the forums:
Do NOT use this version of mysql if you are trying to get WordPress installed using a Windows platform. Read this post originally made to the forums:
如果你试着使用Windows平台安装WordPress,请不要使用这个版本的mysql。请阅读这篇论坛上的文章:
<blockquote>
<blockquote>
"To all those having problems installing Wordpress on your own Windows 2000 (and other Win OS versions) workstation - and maybe some host servers, too: Do not use MySQL 4.1.7 - it is the problem if you get "Error establishing a database connection!". It does not seem compatible with the other components. Use MYSQL 4.0.22 instead.  
"To all those having problems installing Wordpress on your own Windows 2000 (and other Win OS versions) workstation - and maybe some host servers, too: Do not use MySQL 4.1.7 - it is the problem if you get "Error establishing a database connection!". It does not seem compatible with the other components. Use MYSQL 4.0.22 instead.  
<blockquote>
"写给所有在Windows 2000 (或者其它Win OS 版本)平台上安装Wordpress遇到问题的人们- 可能也有一些主机服务器: 不要使用MySQL 4.1.7 – 会产生问题 "错误建立数据库连接!"。似乎与其它部分不兼容。请使用 MYSQL 4.0.22 代替。


Thanks to the Reply by ADAMANT in response to the POST of Nov 6, 2004 02:21:29 by ANTOINE, the Wordpress installation really did become only 5 minutes, after two days of frustration:
Thanks to the Reply by ADAMANT in response to the POST of Nov 6, 2004 02:21:29 by ANTOINE, the Wordpress installation really did become only 5 minutes, after two days of frustration:
感谢ADAMANT回复ANTOINE在2004年11月6日,02:21:29发表的文章,经过两天的尝试,Wordpress真的只需要5分钟就可以安装了:


I started with Windows 2000, PHP 4.3.9, Apache 1.3.33 and MySQL 4.1.7. I spent two days checking my wp-config.php literally 100 times; making changes; troubleshooting my database, using every known name for my host (localhost, 127.0.0.1, <IP address>, computer name, etc...) to no avail. I kept getting:
I started with Windows 2000, PHP 4.3.9, Apache 1.3.33 and MySQL 4.1.7. I spent two days checking my wp-config.php literally 100 times; making changes; troubleshooting my database, using every known name for my host (localhost, 127.0.0.1, <IP address>, computer name, etc...) to no avail. I kept getting:
我从Windows 2000,PHP4.3.9,Apache1.3.33和MySQL4.1.7开始。我花了两天的时间逐字检查了我的wp-config.php100次;做出更改;发现并且解决我的数据库问题,为我的主机使用每个已知的名称(localhost, 127.0.0.1, <IP 地址>,电脑名,等等...)但是没有用。我还是收到:


"Error establishing a database connection!" ...
"Error establishing a database connection!" ...
"错误建立了数据库连接!" ...


I knew it wasn't my config. So thanks to ADAMANT's suggestion, I uninstalled MySQL 4.1.7 and downloaded and installed MySQL 4.0.22 from mysql.org. After installing and configuring the new (old) MySQL, which took approximately 7 minutes (very easy), I ran the install.php once again and YES!! it actually took less than 5 minutes for the Wordpress install.
I knew it wasn't my config. So thanks to ADAMANT's suggestion, I uninstalled MySQL 4.1.7 and downloaded and installed MySQL 4.0.22 from mysql.org. After installing and configuring the new (old) MySQL, which took approximately 7 minutes (very easy), I ran the install.php once again and YES!! it actually took less than 5 minutes for the Wordpress install.
我知道这不是我的配置。因此非常感谢ADAMANT的建议,我卸载了MySQL4.1.7并且从mysql.org中下载并且安装了MySQL。安装并且配置了新的(旧的)MySQL,大概需要7分钟(非常简单),我再次运行install.php并且成功了!!安装Wordpress真的没有花到5分钟。


NOTE: the Apache web site says NOT to use Apache 2 in production. So, after all my wasted time with the latest MySQL, I suggest the following to those who can control their environment:
NOTE: the Apache web site says NOT to use Apache 2 in production. So, after all my wasted time with the latest MySQL, I suggest the following to those who can control their environment:
PHP 4.3.9, Apache 1.3.33 and MySQL 4.0.22. On Windows at least, they all work well together."
PHP 4.3.9, Apache 1.3.33 and MySQL 4.0.22. On Windows at least, they all work well together."


注:Apache网站显示不在产品中使用Apache2.因此,我浪费了这麽多时间处理MySQL后,我给那些能够控制环境的人,建议以下内容:
PHP 4.3.9, Apache 1.3.33 和 MySQL 4.0.22。至少在Windows上,他们一起运行很好。"
Steven
Steven
</blockquote>
</blockquote>
['''UPDATE''': MySQL 4.1.7 uses a new password encryption system that is incompatible with prior methods.  If you want to get WordPress working with a 4.1.7 database, you need to make sure your user password is set as an old-style password (password-old instead of password, if you're using mysqladmin).  -- Nabil]
['''UPDATE''': MySQL 4.1.7 uses a new password encryption system that is incompatible with prior methods.  If you want to get WordPress working with a 4.1.7 database, you need to make sure your user password is set as an old-style password (password-old instead of password, if you're using mysqladmin).  -- Nabil]
Note : The above are actual user comments, and may be subjective in their content. It is hoped that it will be of help to some users who face the specific problems that are addressed by this question..
Note : The above are actual user comments, and may be subjective in their content. It is hoped that it will be of help to some users who face the specific problems that are addressed by this question..
Steven
</blockquote>
['''更新''':MySQL4.1.7使用新的密码加密系统,这个系统与先前的方法不兼容。如果你希望WordPress在4.1.7数据库上能够运行,你需要确定你的用户密码设置为旧样式的密码(如果你使用mysqladmin,旧样式的密码而不是密码)。--Nabil]
注:以上内容是真正的用户评论,而且内容可能有些主观。希望这写评论,遇到评论中提到的相同问题的用户,有帮助。


==Why does WordPress use MySQL?==
==Why does WordPress use MySQL?==
==为什么WordPress 使用 MySQL?==


MySQL is extremely fast. It's also the most widely available database server in the world. Open-source and free, MySQL is supported by thousands of low-cost Linux (and Windows!) hosts, which means a very low barrier to entry for anyone wanting to start a WordPress (or database-driven) website. MySQL's [http://www.mysql.com/documentation/ documentation] is useful, cogent and thorough. (Though it may be intimidating if you're new to all this.) Add to all that the fact that users are able to directly manipulate MySQL with [[WordPress:phpMyAdmin]], developed expressly for that purpose, and it's obvious that MySQL is the best choice. Of course, WordPress insists on the best.
MySQL is extremely fast. It's also the most widely available database server in the world. Open-source and free, MySQL is supported by thousands of low-cost Linux (and Windows!) hosts, which means a very low barrier to entry for anyone wanting to start a WordPress (or database-driven) website. MySQL's [http://www.mysql.com/documentation/ documentation] is useful, cogent and thorough. (Though it may be intimidating if you're new to all this.) Add to all that the fact that users are able to directly manipulate MySQL with [[WordPress:phpMyAdmin]], developed expressly for that purpose, and it's obvious that MySQL is the best choice. Of course, WordPress insists on the best.
MySQL非常地快,也是世界上最常用的数据库服务器。开放源码而且是免费的,MySQL由成千上万个低成本的Linux(和Windows!)主机支持,意思是任何人想要启动WordPress网站(或者数据库驱动的网站)遇到的阻碍都较小。MySQL的[http://www.mysql.com/documentation/ 文档]有用,彻底,恰到好处。(如果你对这个文档不熟悉,你可能仍然还心存疑惑)。此外,用户能够直接地使用[[WordPress:phpMyAdmin|phpMyAdmin]]操作MySQL,毫无疑问,MySQL是最佳的选择。当然,WordPress总是坚持选择最好的。


There are several other excellent database storage engines, such as PostgreSQL and SQLite that WordPress is interested in supporting in the future. Suppporting multiple databases is trickier than it sounds and is not under active development, although there are plenty of architectural discussions about the best approach to take.  Approaches for increasing the number of supported databases are discussed at [[WordPress:Using Alternative Databases]].  There is a PostgreSQL port of WordPress available called [http://wordpress-pg.sourceforge.net/ WordPress-Pg].
There are several other excellent database storage engines, such as PostgreSQL and SQLite that WordPress is interested in supporting in the future. Suppporting multiple databases is trickier than it sounds and is not under active development, although there are plenty of architectural discussions about the best approach to take.  Approaches for increasing the number of supported databases are discussed at [[WordPress:Using Alternative Databases]].  There is a PostgreSQL port of WordPress available called [http://wordpress-pg.sourceforge.net/ WordPress-Pg].
还有一些其它的非常棒的数据库储存引擎,如PostgreSQL 和SQLite,WordPress希望将来能够支持这些引擎。支持多个数据库比听起来复杂,而且当前正在发展中,有许多关于支持多个数据库的方法讨论。关于支持多个数据库的方法讨论在[[WordPress:Using Alternative Databases|使用其它的数据库]]中。WordPress拥有的PostgreSQL端口称为[http://wordpress-pg.sourceforge.net/ WordPress-Pg]。


== Upload Path ==
== Upload Path ==
== 上传路径 ==


When you specified the upload path, you used backslashes.
When you specified the upload path, you used backslashes.
规定了俄上传路径,你使用反斜线符号。


Use forward slashes "/" to specify the directory.
Use forward slashes "/" to specify the directory.
使用顺斜线符号"/"规定目录。


<!-- == Reset Password ==
<!-- == Reset Password ==
<!-- == 重新设置密码  ==


{{merge-section-into|[[WordPress:Resetting your password]]}}
{{merge-section-into|[[WordPress:Resetting your password]]}}
{{将部分合并到|[[WordPress:Resetting your password|重新设置你的密码]]}}


Passwords for WordPress users are stored in an encrypted format called MD5.  This is a relatively common security technique that prevents a hacker from obtaining a list of passwords even if they obtain direct access to the database tables.  MD5 is a one-way hashing procedure, meaning that it verges on the impossible to restore an encrypted password to its original form.
Passwords for WordPress users are stored in an encrypted format called MD5.  This is a relatively common security technique that prevents a hacker from obtaining a list of passwords even if they obtain direct access to the database tables.  MD5 is a one-way hashing procedure, meaning that it verges on the impossible to restore an encrypted password to its original form.
WordPress用户的密码储存在已加密的称为MD5的格式中。这是相对普通的安全方法,黑色技术直接地访问数据库表格,这种方法也能够阻止黑客得到密码列表。Md5是单行的hashing过程,意思是几乎不能以最初的格式重新储存已加密的密码。


Because WordPress uses MD5 to encrypt passwords in the database, a password must be encrypted ''before'' it is inserted in the database.  The MySQL database provides tools for this purpose, and there are many tools available online to create MD5 hashes from passwords.
Because WordPress uses MD5 to encrypt passwords in the database, a password must be encrypted ''before'' it is inserted in the database.  The MySQL database provides tools for this purpose, and there are many tools available online to create MD5 hashes from passwords.
因为WordPress使用MD5加密数据库中的密码,密码在插入数据库''之前'',必须加密。MySQL提供工具执行这个操作,有许多在线工具可以用来从密码中创建MD5 hashes。


Visit this [http://bfl.rctek.com/tools/?tool=hasher MD5 Hasher] to get an MD5 hash of a password instantly, or if you know the Python language, [http://www.python.org/cgi-bin/moinmoin/Md5Passwords use this Python code].
Visit this [http://bfl.rctek.com/tools/?tool=hasher MD5 Hasher] to get an MD5 hash of a password instantly, or if you know the Python language, [http://www.python.org/cgi-bin/moinmoin/Md5Passwords use this Python code].


请访问这个[http://bfl.rctek.com/tools/?tool=hasher MD5 Hasher]立马得到密码的MD5 hash,或者如果你懂得Python语,[http://www.python.org/cgi-bin/moinmoin/Md5Passwords 请使用这个Python代码]。


'''For phpMyAdmin'''


'''For phpMyAdmin'''
'''关于 phpMyAdmin'''


If you have [[WordPress:phpMyAdmin]] access on your server, you can do the following to reset your admin password manually in case you need to :
If you have [[WordPress:phpMyAdmin]] access on your server, you can do the following to reset your admin password manually in case you need to :
如果你能够使用[[WordPress:phpMyAdmin|phpMyAdmin]]访问你的服务器,你可以执行以下的操作,如果需要的话,动手重新设置你的管理密码:


# Open phpMyadmin and be sure that your WordPress database is selected.
# Open phpMyadmin and be sure that your WordPress database is selected.
#打开phpMyadmin并且确定已经选择了你的WordPress数据库。
# Click on the users table in the left menu (it could be wp_users, or ''yourprefix_''users)
# Click on the users table in the left menu (it could be wp_users, or ''yourprefix_''users)
#点击左边菜单中的用户表格(可能是wp_users, 或者 ''yourprefix_''用户)
# Click "Browse" at the top of the right frame.
# Click "Browse" at the top of the right frame.
#在右边框架的顶上方点击"浏览"。
# Click on the edit button next to the admin user.
# Click on the edit button next to the admin user.
#点击管理用户旁边的编辑按钮。
# Replace whatever is in the user_pass field with your new password or MD5 hash.
# Replace whatever is in the user_pass field with your new password or MD5 hash.
#将user_pass栏中的内容替换为你的新密码或者MD5 hash。
# If your password is not already encrypted, select “MD5â€? from the dropdown in the Function column for the user_pass field.  (phpMyAdmin will encrypt your password in MD5 if this is set)
# If your password is not already encrypted, select “MD5â€? from the dropdown in the Function column for the user_pass field.  (phpMyAdmin will encrypt your password in MD5 if this is set)
#如果你的密码还没有加密,从user_pass栏中的函数栏中的下拉列表上选择“MD5â€?。(phpMyAdmin会以MD5的形式给你的密码加密)
# Save the info in the database by clicking "Go" at the bottom of the form.
# Save the info in the database by clicking "Go" at the bottom of the form.
#通过点击表格底部的"Go"(运行)按钮,将信息保存到数据库中。
# Login to Wordpress using “admin� and the password you used to create the hash.
# Login to Wordpress using “admin� and the password you used to create the hash.
#使用“adminâ€?登录到Wordpress,你使用的密码创建了hash。


'''For command line MySQL'''
'''For command line MySQL'''
'''关于命令行MySQL'''


You might have direct access to your MySQL database from the command line.  Usually this is done by sitting at your server, connecting directly to your server via SSH, or using the MySQL client on your workstation to connect to your server.  You must be in the correct context to successfully execute the ''mysql'' command mentioned below.
You might have direct access to your MySQL database from the command line.  Usually this is done by sitting at your server, connecting directly to your server via SSH, or using the MySQL client on your workstation to connect to your server.  You must be in the correct context to successfully execute the ''mysql'' command mentioned below.
你可能能够从命令行中直接访问你的MySQL数据库。通过坐在你的服务器旁边,通过SSH直接连接到你的服务器,或者在你的工作台上使用MySQL client连接到你的服务器。你必须在合适的语境中,成功地执行下面提到的''mysql''命令。


To reset your WordPress password from the MySQL command line, do the following (replace the options in italics with your settings):
To reset your WordPress password from the MySQL command line, do the following (replace the options in italics with your settings):
要从MySQL命令行中重新设置你的WordPress密码,请执行以下的操作(使用你的设置替换斜体字的选项):


# "mysql -u root -p" (Logs in to MySQL)
# "mysql -u root -p" (Logs in to MySQL)
# "mysql -u root -p"(登录到MySQL)
# Enter your password at the prompt.
# Enter your password at the prompt.
#即时输入你的密码。
# "use <i>name-of-database</i>" (Selects your WordPress database)
# "use <i>name-of-database</i>" (Selects your WordPress database)
# "use <i>name-of-database</i>"(选择你的WordPress数据库)
# "show tables LIKE '%users';" (Finds the WordPress user table)
# "show tables LIKE '%users';" (Finds the WordPress user table)
# "show tables LIKE '%users';"(找到WordPress用户表格)
# "SELECT ID, user_login, user_pass FROM <i>name-of-table-you-found</i> WHERE user_login = '<i>username</i>';" (Observe the encrypted password)
# "SELECT ID, user_login, user_pass FROM <i>name-of-table-you-found</i> WHERE user_login = '<i>username</i>';" (Observe the encrypted password)
# "SELECT ID, user_login, user_pass FROM <i>name-of-table-you-found</i> WHERE user_login = '<i>username</i>';" (观察已加密的密码)
# "UPDATE <i>name-of-table-you-found</i> SET user_pass=MD5('<i>new-unencrypted-password</i>') WHERE user_login = '<i>username</i>';"  (Updates the database with the encrypted password)
# "UPDATE <i>name-of-table-you-found</i> SET user_pass=MD5('<i>new-unencrypted-password</i>') WHERE user_login = '<i>username</i>';"  (Updates the database with the encrypted password)
# "UPDATE <i>name-of-table-you-found</i> SET user_pass=MD5('<i>new-unencrypted-password</i>') WHERE user_login = '<i>username</i>';"  (使用已加密的密码更新数据库)
# "SELECT ID, user_login, user_pass FROM <i>name-of-table-you-found</i> WHERE user_login = '<i>username</i>';" (Confirm that it was changed)
# "SELECT ID, user_login, user_pass FROM <i>name-of-table-you-found</i> WHERE user_login = '<i>username</i>';" (Confirm that it was changed)
# "SELECT ID, user_login, user_pass FROM <i>name-of-table-you-found</i> WHERE user_login = '<i>username</i>';" (确定已更改)
# "exit" (Exits the MySQL client)
# "exit" (Exits the MySQL client)
# "exit" (退出 MySQL client)
# Login to WordPress using the username and password that you've altered.
# Login to WordPress using the username and password that you've altered.
-->
#使用你已经更改的用户名和密码登录到WordPress。
-->
-->


== Delete Files ==
== Delete Files ==
== 删除文件==


There are no files that you must delete.
There are no files that you must delete.
没有你必须删除的文件。
There are no risks to your WordPress files or your database by leaving all the files exactly as they were when you uploaded them.
There are no risks to your WordPress files or your database by leaving all the files exactly as they were when you uploaded them.
当你上传文件的时候,使得文件保存原状,对你的WordPress文件或者你的数据库没有什么风险。


However, it is safe to delete the following:
However, it is safe to delete the following:
然而,删除下面的内容是安全的:
*license.txt
*license.txt
*Readme.html
*Readme.html
*the import*.php files
*the import*.php files
*license.txt
*Readme.html
*the import*.php 文件


== Rename Folder ==
== Rename Folder ==
== 重新命名文件夹==


If you have not installed WordPress, you can rename the folder with the WordPress files.
If you have not installed WordPress, you can rename the folder with the WordPress files.
如果你没有安装WordPress,你可以使用WordPress文件重新命名文件夹。


If you have already installed WordPress, and you want to rename the folder, login to the weblog as the administrator and change the following settings in Options->General :
If you have already installed WordPress, and you want to rename the folder, login to the weblog as the administrator and change the following settings in Options->General :
如果你已经安装了WordPress,而且你想要重新命名文件夹,以管理员身份登录到博客,在选项->总中,更改以下的设置:


* WordPress address (URI):
* WordPress address (URI):
* Blog address (URI):
* Blog address (URI):
* WordPress 地址 (URI):
* 博客地址(URI):


Once you have done this, you can rename the directory or folder with the wordpress files in it.
Once you have done this, you can rename the directory or folder with the wordpress files in it.
完成这个操作之后,你可以重新命名WordPress文件的目录或者文件夹。


== Safe Mode ==
== Safe Mode ==
== 安全模式==


Most definitely! There are no known issues with any version of WordPress when PHP is running in Safe Mode.
Most definitely! There are no known issues with any version of WordPress when PHP is running in Safe Mode.
非常确定!当PHP在安全模式下运行的时候,任何版本的WordPress都没有问题。
== allow_url_fopen ==


== allow_url_fopen ==
== allow_url_fopen ==


In order to accept incoming pingbacks, you have to set 'allow_url_fopen = On' in php.ini.
In order to accept incoming pingbacks, you have to set 'allow_url_fopen = On' in php.ini.
为了要接受即将到来的pingbacks,你需要设置'allow_url_fopen = On' in php.ini.


== 403 Error ==
== 403 Error ==
== 403 错误==


Symptoms:
Symptoms:
症状:
You cannot seem to login after using the right username and password, into your admin account.
You cannot seem to login after using the right username and password, into your admin account.
在你的管理帐户上输入正确的用户名和密码之后,你似乎还是不能够登录。


You get an error message like :
You get an error message like :
你得到错误信息,如:
  You are not authorized to view this page
  You are not authorized to view this page
  You might not have permission to view this directory or page using the credentials you supplied.
  You might not have permission to view this directory or page using the credentials you supplied.
第126行: 第288行:
  HTTP Error 403 - Forbidden''
  HTTP Error 403 - Forbidden''


Solution:
你没有得到授权浏览这个页面
If your account is hosted on a Windows server, it could be a problem with the Directory Indexes. The default configuration of the server is to load index.htm, index.html, default.htm, default.html, default.asp files.
你可能没有权限浏览这个目录或者页面,请使用你支持的权限
如果你相信你能够浏览这个目录或者页面,情是这个联系网站,使用列在personal.rbhemauer.com主页上的电子邮件地址或者电话号码。你可以点击搜索,查找因特网上的信息。
HTTP错误403-禁止''
 
Solution:If your account is hosted on a Windows server, it could be a problem with the Directory Indexes. The default configuration of the server is to load index.htm, index.html, default.htm, default.html, default.asp files.
 
解决办法:如果你的帐户托管在Windows服务器上,可能是目录索引的问题。服务器默认配置是要上传index.htm, index.html, default.htm, default.html, default.asp文件。


Wordpress is done in PHP so the default page is index.php. Now this is not part of the default configuration so we need to add it. To do this, you need to click on Web Options in the Control Panel. Then scroll down to the Directory Indexes section to add index.php to the Directory Indexes.
Wordpress is done in PHP so the default page is index.php. Now this is not part of the default configuration so we need to add it. To do this, you need to click on Web Options in the Control Panel. Then scroll down to the Directory Indexes section to add index.php to the Directory Indexes.
Wordpress是以PHP编写的,因此默认页面是index.php。现在这不是默认配置的一部分,因此我们需要添加。你需要点击控制面板上的网络选项。然后下滚至目录索引部分,将index.php添加到目录索引。


You could also contact your webhost for support in this matter.
You could also contact your webhost for support in this matter.
你也可以联系你的网络主机得到这个问题的相关支持。


== Create Database ==
== Create Database ==
== 创建数据库 ==


In the setup of WordPress, it will ask to setup the database. The appropriate answers are "Yes" and "No".
In the setup of WordPress, it will ask to setup the database. The appropriate answers are "Yes" and "No".
创建WordPress时,会要求你创建数据库。合适的答案是"是的"  和"不是"。


* If your hosting plan allows only one [[WordPress:Glossary#MySQL|MySQL database]], you will probably need to answer "Yes".
* If your hosting plan allows only one [[WordPress:Glossary#MySQL|MySQL database]], you will probably need to answer "Yes".
*如果你的托管方案只允许一个[[WordPress:Glossary#MySQL|MySQL 数据库]],你可能需要回答"是的"。


* If your [[WordPress:Using_cPanel|cPanel]] tells you the name of your [[WordPress:Glossary#MySQL|MySQL database]], then just enter that into DB NAME in [[WordPress:Editing wp-config.php|wp-config.php]].
* If your [[WordPress:Using_cPanel|cPanel]] tells you the name of your [[WordPress:Glossary#MySQL|MySQL database]], then just enter that into DB NAME in [[WordPress:Editing wp-config.php|wp-config.php]].
*如果你的[[WordPress:Using_cPanel|cPanel]]向你显示你的[[WordPress:Glossary#MySQL|MySQL数据库]]的名称,那么只要将这个名称输入[[WordPress:Editing wp-config.php|wp-config.php]]中的DB名称。


* If you have multiple databases you can use, you will need to create the database, and then assign that name to DB NAME in [[WordPress:Editing wp-config.php|wp-config.php]] so that WordPress knows which database to use when installing.
* If you have multiple databases you can use, you will need to create the database, and then assign that name to DB NAME in [[WordPress:Editing wp-config.php|wp-config.php]] so that WordPress knows which database to use when installing.
*如果你可以使用多个数据库,你需要创建数据库,然后将这个数据库名递交到[[WordPress:Editing wp-config.php|wp-config.php]]中的DB名,这样,WordPress知道安装的时候,使用哪个数据库。


* See [[WordPress:Installation#Detailed_Instructions|Installation, Detailed Instructions]]
* See [[WordPress:Installation#Detailed_Instructions|Installation, Detailed Instructions]]
*请看看[[WordPress:Installation#Detailed_Instructions|安装,详细的指示说明]]


== PHP Version ==
== PHP Version ==
== PHP 版本 ==
To get information about your server, you can use the PHP Info function:
To get information about your server, you can use the PHP Info function:
得到关于你的服务器的信息,你可以使用PHP信息函数:


*Paste this into a new Notepad / BBEdit file
*Paste this into a new Notepad / BBEdit file
*将这个粘贴到新的Notepad / BBEdit文件
<pre><?php phpinfo(); ?></pre>


<pre><?php phpinfo(); ?></pre>
<pre><?php phpinfo(); ?></pre>


*Save as '''info.php'''
*Save as '''info.php'''
*作为'''info.php'''保存


*Upload to server. Visit in your browser (www.example.com/info.php)
*Upload to server. Visit in your browser (www.example.com/info.php)
*上传到服务器。在你的浏览器中访问(www.example.com/info.php)


*That will give you info about your php version and [[WordPress:Glossary#mod_rewrite| mod_rewrite]].
*That will give you info about your php version and [[WordPress:Glossary#mod_rewrite| mod_rewrite]].
*这个站点会向你提供有关你的php版本和[[WordPress:Glossary#mod_rewrite| mod_rewrite]]的信息。


== Multiple Blogs ==
== Multiple Blogs ==
== 多个博客==


See: [[WordPress:Installing Multiple Blogs]]
See: [[WordPress:Installing Multiple Blogs]]


请看看:[[WordPress:Installing Multiple Blogs|安装多个博客]]
== Apache ==


== Apache ==  
== Apache ==  


WordPress works best on [[WordPress:Glossary#Apache|Apache]] 2.x To see your version, the phpinfo script above will tell you what version of Apache your server is running.
WordPress works best on [[WordPress:Glossary#Apache|Apache]] 2.x To see your version, the phpinfo script above will tell you what version of Apache your server is running.
WordPress在[[WordPress:Glossary#Apache|Apache]] 2.x上能够最好地运行。要查看你的版本,上述的phpinfo 脚本会提示你的你的服务器正在运行哪个版本的Apache。


Note: If you are running WordPress 1.5 on [[WordPress:Glossary#Apache|Apache]] 1.3.x you will have trouble [[WordPress:Using Permalinks]] with  the %category% permalink structure. "If you are using Apache 1, do not use %category% in your permalink structure."
Note: If you are running WordPress 1.5 on [[WordPress:Glossary#Apache|Apache]] 1.3.x you will have trouble [[WordPress:Using Permalinks]] with  the %category% permalink structure. "If you are using Apache 1, do not use %category% in your permalink structure."
注意:如果你在[[WordPress:Glossary#Apache|Apache]] 1.3.x上运行WordPress1.5,你[[WordPress:Using Permalinks|使用Permalinks]]会遇到%category% permalink结构的问题。"如果你正在使用Apache 1 ,请不要在到你的premalink结构中使用%category%。"

2008年9月20日 (六) 11:57的最新版本


These FAQs have been deprecated. You will find the new updated Frequently Asked Questions on the new pages for the WordPress:FAQ.

这些常见问题解答已经取消了。你在常见问题解答的新的页面上会看到新的已更新的常见问题解答

Back to FAQ 返回到常见问题解答

PHP and MySQL Requirements[ ]

PHP 和MySQL 要求[ ]

You certainly need PHP (version 4.1 or newer) and MySQL (version 3.23.23 or newer) to power your WordPress blog. PHP is the scripting language that drives all of WordPress, and without PHP, your server will not be able to interpret the pages that create your weblog. MySQL is a relational database, and WordPress works only with MySQL. Other databases are not supported at the moment.

你当然需要PHP(4.1版本或者更新)和MySQL(3.23.23版本或者更新)支持你的WordPress博客。PHP是种脚本语言,运行WordPress的所有部分,如果没有PHP,你的服务器就不能够翻译创建你的博客的页面。MySQL是关系数据库,而且WordPress与MySQL一起运行。暂时不支持其它的数据库。

MySQL 4.1.7[ ]

MySQL 4.1.7[ ]

Do NOT use this version of mysql if you are trying to get WordPress installed using a Windows platform. Read this post originally made to the forums:

如果你试着使用Windows平台安装WordPress,请不要使用这个版本的mysql。请阅读这篇论坛上的文章:

"To all those having problems installing Wordpress on your own Windows 2000 (and other Win OS versions) workstation - and maybe some host servers, too: Do not use MySQL 4.1.7 - it is the problem if you get "Error establishing a database connection!". It does not seem compatible with the other components. Use MYSQL 4.0.22 instead.

"写给所有在Windows 2000 (或者其它Win OS 版本)平台上安装Wordpress遇到问题的人们- 可能也有一些主机服务器: 不要使用MySQL 4.1.7 – 会产生问题 "错误建立数据库连接!"。似乎与其它部分不兼容。请使用 MYSQL 4.0.22 代替。

Thanks to the Reply by ADAMANT in response to the POST of Nov 6, 2004 02:21:29 by ANTOINE, the Wordpress installation really did become only 5 minutes, after two days of frustration:

感谢ADAMANT回复ANTOINE在2004年11月6日,02:21:29发表的文章,经过两天的尝试,Wordpress真的只需要5分钟就可以安装了:

I started with Windows 2000, PHP 4.3.9, Apache 1.3.33 and MySQL 4.1.7. I spent two days checking my wp-config.php literally 100 times; making changes; troubleshooting my database, using every known name for my host (localhost, 127.0.0.1, <IP address>, computer name, etc...) to no avail. I kept getting:

我从Windows 2000,PHP4.3.9,Apache1.3.33和MySQL4.1.7开始。我花了两天的时间逐字检查了我的wp-config.php100次;做出更改;发现并且解决我的数据库问题,为我的主机使用每个已知的名称(localhost, 127.0.0.1, <IP 地址>,电脑名,等等...)但是没有用。我还是收到:

"Error establishing a database connection!" ...

"错误建立了数据库连接!" ...

I knew it wasn't my config. So thanks to ADAMANT's suggestion, I uninstalled MySQL 4.1.7 and downloaded and installed MySQL 4.0.22 from mysql.org. After installing and configuring the new (old) MySQL, which took approximately 7 minutes (very easy), I ran the install.php once again and YES!! it actually took less than 5 minutes for the Wordpress install.

我知道这不是我的配置。因此非常感谢ADAMANT的建议,我卸载了MySQL4.1.7并且从mysql.org中下载并且安装了MySQL。安装并且配置了新的(旧的)MySQL,大概需要7分钟(非常简单),我再次运行install.php并且成功了!!安装Wordpress真的没有花到5分钟。

NOTE: the Apache web site says NOT to use Apache 2 in production. So, after all my wasted time with the latest MySQL, I suggest the following to those who can control their environment: PHP 4.3.9, Apache 1.3.33 and MySQL 4.0.22. On Windows at least, they all work well together."

注:Apache网站显示不在产品中使用Apache2.因此,我浪费了这麽多时间处理MySQL后,我给那些能够控制环境的人,建议以下内容: PHP 4.3.9, Apache 1.3.33 和 MySQL 4.0.22。至少在Windows上,他们一起运行很好。" Steven

[UPDATE: MySQL 4.1.7 uses a new password encryption system that is incompatible with prior methods. If you want to get WordPress working with a 4.1.7 database, you need to make sure your user password is set as an old-style password (password-old instead of password, if you're using mysqladmin). -- Nabil] Note : The above are actual user comments, and may be subjective in their content. It is hoped that it will be of help to some users who face the specific problems that are addressed by this question..

Steven

[更新:MySQL4.1.7使用新的密码加密系统,这个系统与先前的方法不兼容。如果你希望WordPress在4.1.7数据库上能够运行,你需要确定你的用户密码设置为旧样式的密码(如果你使用mysqladmin,旧样式的密码而不是密码)。--Nabil] 注:以上内容是真正的用户评论,而且内容可能有些主观。希望这写评论,遇到评论中提到的相同问题的用户,有帮助。

Why does WordPress use MySQL?[ ]

为什么WordPress 使用 MySQL?[ ]

MySQL is extremely fast. It's also the most widely available database server in the world. Open-source and free, MySQL is supported by thousands of low-cost Linux (and Windows!) hosts, which means a very low barrier to entry for anyone wanting to start a WordPress (or database-driven) website. MySQL's documentation is useful, cogent and thorough. (Though it may be intimidating if you're new to all this.) Add to all that the fact that users are able to directly manipulate MySQL with WordPress:phpMyAdmin, developed expressly for that purpose, and it's obvious that MySQL is the best choice. Of course, WordPress insists on the best.

MySQL非常地快,也是世界上最常用的数据库服务器。开放源码而且是免费的,MySQL由成千上万个低成本的Linux(和Windows!)主机支持,意思是任何人想要启动WordPress网站(或者数据库驱动的网站)遇到的阻碍都较小。MySQL的文档有用,彻底,恰到好处。(如果你对这个文档不熟悉,你可能仍然还心存疑惑)。此外,用户能够直接地使用phpMyAdmin操作MySQL,毫无疑问,MySQL是最佳的选择。当然,WordPress总是坚持选择最好的。

There are several other excellent database storage engines, such as PostgreSQL and SQLite that WordPress is interested in supporting in the future. Suppporting multiple databases is trickier than it sounds and is not under active development, although there are plenty of architectural discussions about the best approach to take. Approaches for increasing the number of supported databases are discussed at WordPress:Using Alternative Databases. There is a PostgreSQL port of WordPress available called WordPress-Pg.

还有一些其它的非常棒的数据库储存引擎,如PostgreSQL 和SQLite,WordPress希望将来能够支持这些引擎。支持多个数据库比听起来复杂,而且当前正在发展中,有许多关于支持多个数据库的方法讨论。关于支持多个数据库的方法讨论在使用其它的数据库中。WordPress拥有的PostgreSQL端口称为WordPress-Pg

Upload Path[ ]

上传路径[ ]

When you specified the upload path, you used backslashes.

规定了俄上传路径,你使用反斜线符号。

Use forward slashes "/" to specify the directory.

使用顺斜线符号"/"规定目录。


  1. 使用你已经更改的用户名和密码登录到WordPress。

-->

Delete Files[ ]

删除文件[ ]

There are no files that you must delete.

没有你必须删除的文件。

There are no risks to your WordPress files or your database by leaving all the files exactly as they were when you uploaded them.

当你上传文件的时候,使得文件保存原状,对你的WordPress文件或者你的数据库没有什么风险。

However, it is safe to delete the following:

然而,删除下面的内容是安全的:

  • license.txt
  • Readme.html
  • the import*.php files
  • license.txt
  • Readme.html
  • the import*.php 文件

Rename Folder[ ]

重新命名文件夹[ ]

If you have not installed WordPress, you can rename the folder with the WordPress files.

如果你没有安装WordPress,你可以使用WordPress文件重新命名文件夹。

If you have already installed WordPress, and you want to rename the folder, login to the weblog as the administrator and change the following settings in Options->General :

如果你已经安装了WordPress,而且你想要重新命名文件夹,以管理员身份登录到博客,在选项->总中,更改以下的设置:

  • WordPress address (URI):
  • Blog address (URI):
  • WordPress 地址 (URI):
  • 博客地址(URI):

Once you have done this, you can rename the directory or folder with the wordpress files in it.

完成这个操作之后,你可以重新命名WordPress文件的目录或者文件夹。

Safe Mode[ ]

安全模式[ ]

Most definitely! There are no known issues with any version of WordPress when PHP is running in Safe Mode.

非常确定!当PHP在安全模式下运行的时候,任何版本的WordPress都没有问题。

allow_url_fopen[ ]

allow_url_fopen[ ]

In order to accept incoming pingbacks, you have to set 'allow_url_fopen = On' in php.ini.

为了要接受即将到来的pingbacks,你需要设置'allow_url_fopen = On' in php.ini.

403 Error[ ]

403 错误[ ]

Symptoms:

症状:

You cannot seem to login after using the right username and password, into your admin account.

在你的管理帐户上输入正确的用户名和密码之后,你似乎还是不能够登录。

You get an error message like :

你得到错误信息,如:

You are not authorized to view this page
You might not have permission to view this directory or page using the credentials you supplied.
If you believe you should be able to view this directory or page, please try to contact the Web 
site by using any e-mail address or phone number that may be listed on the personal.rbhemauer.com
home page. You can click Search to look for information on the Internet. 
HTTP Error 403 - Forbidden

你没有得到授权浏览这个页面 你可能没有权限浏览这个目录或者页面,请使用你支持的权限 如果你相信你能够浏览这个目录或者页面,情是这个联系网站,使用列在personal.rbhemauer.com主页上的电子邮件地址或者电话号码。你可以点击搜索,查找因特网上的信息。 HTTP错误403-禁止

Solution:If your account is hosted on a Windows server, it could be a problem with the Directory Indexes. The default configuration of the server is to load index.htm, index.html, default.htm, default.html, default.asp files.

解决办法:如果你的帐户托管在Windows服务器上,可能是目录索引的问题。服务器默认配置是要上传index.htm, index.html, default.htm, default.html, default.asp文件。

Wordpress is done in PHP so the default page is index.php. Now this is not part of the default configuration so we need to add it. To do this, you need to click on Web Options in the Control Panel. Then scroll down to the Directory Indexes section to add index.php to the Directory Indexes.

Wordpress是以PHP编写的,因此默认页面是index.php。现在这不是默认配置的一部分,因此我们需要添加。你需要点击控制面板上的网络选项。然后下滚至目录索引部分,将index.php添加到目录索引。

You could also contact your webhost for support in this matter.

你也可以联系你的网络主机得到这个问题的相关支持。

Create Database[ ]

创建数据库[ ]

In the setup of WordPress, it will ask to setup the database. The appropriate answers are "Yes" and "No".

创建WordPress时,会要求你创建数据库。合适的答案是"是的" 和"不是"。

  • If your hosting plan allows only one MySQL database, you will probably need to answer "Yes".
  • 如果你的托管方案只允许一个MySQL 数据库,你可能需要回答"是的"。
  • If you have multiple databases you can use, you will need to create the database, and then assign that name to DB NAME in wp-config.php so that WordPress knows which database to use when installing.
  • 如果你可以使用多个数据库,你需要创建数据库,然后将这个数据库名递交到wp-config.php中的DB名,这样,WordPress知道安装的时候,使用哪个数据库。

PHP Version[ ]

PHP 版本[ ]

To get information about your server, you can use the PHP Info function:

得到关于你的服务器的信息,你可以使用PHP信息函数:

  • Paste this into a new Notepad / BBEdit file
  • 将这个粘贴到新的Notepad / BBEdit文件
<?php phpinfo(); ?>
<?php phpinfo(); ?>
  • Save as info.php
  • 作为info.php保存
  • Upload to server. Visit in your browser (www.example.com/info.php)
  • 上传到服务器。在你的浏览器中访问(www.example.com/info.php)
  • That will give you info about your php version and mod_rewrite.
  • 这个站点会向你提供有关你的php版本和 mod_rewrite的信息。

Multiple Blogs[ ]

多个博客[ ]

See: WordPress:Installing Multiple Blogs

请看看:安装多个博客

Apache[ ]

Apache[ ]

WordPress works best on Apache 2.x To see your version, the phpinfo script above will tell you what version of Apache your server is running.

WordPress在Apache 2.x上能够最好地运行。要查看你的版本,上述的phpinfo 脚本会提示你的你的服务器正在运行哪个版本的Apache。

Note: If you are running WordPress 1.5 on Apache 1.3.x you will have trouble WordPress:Using Permalinks with the %category% permalink structure. "If you are using Apache 1, do not use %category% in your permalink structure."

注意:如果你在Apache 1.3.x上运行WordPress1.5,你使用Permalinks会遇到%category% permalink结构的问题。"如果你正在使用Apache 1 ,请不要在到你的premalink结构中使用%category%。"