3 WordPress建站

68 次浏览

WordPress 是目前世界上最流行的内容管理系统(CMS)之一,安装过程相对简单。以下是 WordPress 安装的详细步骤

1、安装WordPress

wget https://cn.wordpress.org/latest-zh_CN.zip

安装unzip

sudo apt-get install unzip

解压wordpress文件到apache2根目录 /var/www/html

sudo unzip latest-zh_CN.zip<br>mv ~/wordpress/* /var/www/html

2、配置WorsPress

此步骤也可在WordPress页面中设置
用模板创建wp-config.php文件

cp /var/www/html/wp-config-sample.php /var/www/html/wp-config.php

编辑wp-config.php

vim wp-config.php

根据创建的数据库和用户名密码

/* MYSQL database name */
define('DB_NAME', 'wordpress');
/* MySQL database username */
define('DB_USER', 'root');
/* MYSQL database password */
define('DB_PASSWORD', 'your_password');

3、登录WordPress

重命名index.html文件

mv index.html index1.html

验证是否配置成功,浏览器访问 https://localhost/wp-admin/install.php

发表评论

您的邮箱地址不会被公开。 必填项已用 * 标注

滚动至顶部