个人工具
104.160.18.24
该IP地址的讨论
登录
查看“UbuntuHelp:WordPress”的源代码 - Ubuntu中文
UbuntuHelp
讨论
查看源代码
历史
搜索
导航
首页
最近更改
随机页面
页面分类
帮助
编辑
编辑指南
沙盒
新闻动态
字词处理
工具
链入页面
相关更改
特殊页面
页面信息
查看“UbuntuHelp:WordPress”的源代码
来自Ubuntu中文
←
UbuntuHelp:WordPress
跳转至:
导航
,
搜索
因为以下原因,你没有权限编辑本页:
您所请求的操作仅限于该用户组的用户使用:
用户
您可以查看与复制此页面的源代码。
{{From|https://help.ubuntu.com/community/WordPress}} {{Languages|UbuntuHelp:WordPress}} [http://www.wordpress.org Wordpress] is a popular web publishing software, most commonly used for weblogs (also known as "blogs"). Follow these instructions to install Wordpress on Ubuntu 6.06 (Dapper Drake). === LAMP Installation === Wordpress runs on the LAMP (Linux, Apache, MySQL, PHP) stack of applications. First you need to install and configure LAMP. See the [[UbuntuHelp:ApacheMySQLPHP|ApacheMySQLPHP]] page. === Enable the Universe repository === * [[UbuntuHelp:Repositories/CommandLine| I am using Ubuntu server (command line)]] * [[UbuntuHelp:AddingRepositoriesHowto| I am using a desktop]] === Install Wordpress === Use [[UbuntuHelp:InstallingSoftware| any method]] to install. <pre><nowiki> wordpress php5-gd </nowiki></pre> An example is using the command line terminal with apt-get install: <pre><nowiki> sudo apt-get install wordpress php5-gd </nowiki></pre> The installation places the files in the /usr/share/wordpress folder, generally. So that Apache2 knows where to find the installation folder, make a symbolic link to the Apache2 www folder: <pre><nowiki> sudo ln -s /usr/share/wordpress /var/www/wordpress </nowiki></pre> Then install WordPress using the supplied script <pre><nowiki> sudo bash /usr/share/doc/wordpress/examples/setup-mysql -n wordpress localhost </nowiki></pre> Note: (Use sh instead of bash for Feisty or earlier.) This script creates the MySQL database user wordpress for the new MySQL database named localhost (that will be used for WordPress). If you will be hosting a virtual host and/or already know your URL, it is best to name your database the same as your URL. For example, if your URL is ''wordpress.mydomain.org'', then the command would be <pre><nowiki> sudo bash /usr/share/doc/wordpress/examples/setup-mysql -n wordpress wordpress.mydomain.org </nowiki></pre> If you will be using a virtual host, create your apache2 virtual host file in the /etc/apache2/sites-available folder. When you are finished, enable it by making a symbolic link from that virtual host file to the sites-enabled folder. However, this can be dangerous until you have secured your WordPress installation against malicious anonymous users on the Internet, so should only be done after the initial installation is complete and anonymous user creation is turned off. Whenever you change your virtual hosts, you must restart Apache2: <pre><nowiki> sudo /etc/init.d/apache2 restart </nowiki></pre> Now, browse to "http://localhost/wordpress" in your browser to install it (or http://''wordpress.mydomain.org''/wordpress if you are using a virtual host). You will be given an initial user named admin and a random password. Write it down. Then login as the admin user and change the password. https://help.ubuntu.com/community/WordPress?action=AttachFile&do=get&target=wordpress1.jpg https://help.ubuntu.com/community/WordPress?action=AttachFile&do=get&target=wordpress2.jpg For automatic updates to occur, the folder and all its files and subfolders must be owned by www-data: <pre><nowiki> chown -R www-data /usr/share/wordpress </nowiki></pre> While logged in to WordPress, do an automatic upgrade from the Tools -> Upgrade option. Once installed, to change the url of your site, link the file /etc/wordpress/config-localhost.php to /etc/wordpress/config-my.url.com.php as well as changing the url in the wordpress configuration Options menu. For example, if my dns was ''hello.homelinux.net'' <pre><nowiki> sudo ln -s /etc/wordpress/config-localhost.php /etc/wordpress/config-hello.homelinux.net.php </nowiki></pre> https://help.ubuntu.com/community/WordPress?action=AttachFile&do=get&target=wordpress3.jpg Change the URLs to: https://help.ubuntu.com/community/WordPress?action=AttachFile&do=get&target=wordpress4.jpg === Troubleshooting === ==== Error when running setup-mysql ==== While installing wordpress you may encounter the following error. <pre><nowiki> $ sudo sh /usr/share/doc/wordpress/examples/setup-mysql -n (your mysql user) localhost /usr/share/doc/wordpress/examples/setup-mysql: 38: Syntax error: Bad substitution </nowiki></pre> This issue seems to be Edgy related. I did not encounter the error using Dapper. Here is a [http://www.mail-archive.com/debian-bugs-dist@lists.debian.org/msg199581.html link] to the bug reported on the Debian mailing list. Note: the issue seems to appear on Gutsy as well, only that the error code is slightly different: <pre><nowiki> /usr/share/doc/wordpress/examples/setup-mysql: 37: Syntax error: Bad substitution </nowiki></pre> To correct this, you first need to remove any configuration that may have already been created: <pre><nowiki> rm /etc/wordpress/config-localhost.php </nowiki></pre> Then run the same command but using ''bash'' instead of ''sh'': <pre><nowiki> sudo bash /usr/share/doc/wordpress/examples/setup-mysql -n (your mysql user) localhost </nowiki></pre> === External Links === The following are unverified suggestions made by users. ==== Turnkey Linux ==== An Ubuntu-based [[UbuntuHelp: http://www.turnkeylinux.org/wordpress | WordPress appliance ]] is one of the easiest ways to get up and running with WordPress on Ubuntu. It's part of a family of pre-integrated [[ http://www.turnkeylinux.org/ Virtual Appliances based on Ubuntu 8.04.3 (Hardy LTS). ==== Curly Braces ==== Curly Braces is an weekly blog on technology. This article : [http://zfranciscus.wordpress.com/2009/10/22/installing-wordpress-in-ubuntu/ Installing WordPress in Ubuntu | target=_blank] provides a step by step guide on how to install the latest version of WordPress ini Ubuntu Jaunty Jackalope [[category:UbuntuHelp]]
该页面使用的模板:
模板:From
(
查看源代码
)
模板:Languages
(
查看源代码
)(受保护)
模板:Languages/Lang
(
查看源代码
)(受保护)
返回至
UbuntuHelp:WordPress
。