1. To run WordPress we recommend your host supports:
- PHP version 7.2 or greater
- MySQL version 5.6 or greater OR MariaDB version 10.0 or greater
- HTTPS support
That’s really it. We recommend Apache or Nginx as the most robust and featureful server for running WordPress, but any server that supports PHP and MySQL will do. That said, we can’t test every possible environment and each of the hosts on our hosting page supports the above and more with no problems.
Note: If you are in a legacy environment where you only have older PHP or MySQL versions, WordPress also works with PHP 5.2.4+ and MySQL 5.0+, but these versions have reached official End Of Life and as such may expose your site to security vulnerabilities.
如果需要简单的话,可以下载与wamp或者lamp类似集成环境,来快速配置系统环境。
2. 下载安装
如果上面的依赖环境已经部署完毕,则可以开始下载安装。
- 登录wordpress官网,下载wordpress文件,解压。
- 把解压后的文件放到apache或者wamp安装目录下的www目录。启动服务。
- 在浏览器里输入127.0.0.1/wordpress,会进入到wordpress的初始化安装页面。
- 首先在MySQL或者MariaDB里创建需要用到的数据库(wordpress通过phpMyAdmin来管理mysql数据库)。然后在页面里设置用到的数据库的名称、用户名、密码,以及数据库的地址:端口号,端口号如果不填,则默认为3306. 填写表前缀,默认是wp_。如果不同的网站用同一个数据库,则需要修改表的前缀名加以区分。
- 如果一切顺利,会安装好数据库,可以自行登录数据库查看生成的表。创建管理员用户,用来在后台启用插件以及一些设置。