In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
Demand:
Due to the business needs of the company's promotion department, set up a WordPress blog website
Introduction:
WordPress is a blog platform developed in PHP language. Users can set up their own websites on servers that support PHP and MySQL databases. You can also use WordPress as a content management system (CMS).
WordPress is a personal blog system, and gradually evolved into a content management system software, it is developed using PHP language and MySQL database, users can use their own blog on servers that support PHP and MySQL databases
Software function
1. Articles are published, classified, archived and collected, and the number of readings is counted.
2. Provide various forms of RSS aggregation such as articles, comments, categories, etc.
3. Provide the function of adding and classifying links.
4. Support comment management and spam filtering function.
5. Support direct editing and modification of multiple CSS and PHP programs.
6. Add the required pages easily outside the Blog system.
7. Make Blog more personalized by setting various parameters.
8. Static html page generation (such as WP-SUPER-CACHE) is implemented with the support of some plug-ins.
9. By selecting different themes, you can easily change the display effect of the page.
10. A variety of special functions can be provided by adding plug-ins.
11. Trackback and pingback are supported.
12. Support the import function for some other blog software and platforms.
13. Support member registration and login, background management function.
Installation environment:
CentOS 7.6 system
Nginx 1.16.1
Mysql 5.7
PHP 7.0.33
Wordpress 5.2.3
First, set up the LNMP environment and install nginx1. Add Nginx to the YUM source
Rpm-Uvh http://nginx.org/packages/centos/7/noarch/RPMS/nginx-release-centos-7-0.el7.ngx.noarch.rpm
two。 Install Nginx
Yum install-y nginx
3. Modify the configuration file
Vim / etc/nginx/nginx.conf
Server {listen 80; root / usr/share/nginx/html; server_name localhost; location / {index index.php index.html index.htm;} error_page 500 502 503 504 / 50x.html; location = / 50x.html {root / usr/share/nginx/html } location ~ .php ${fastcgi_pass 127.0.0.1 fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME 9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $php}
}
4. Start Nginx
Systemctl start nginx
To install PHP, please refer to the blog https://blog.51cto.com/13760351/2442298PHP configuration 1. Configure the storage path for PHP Session
Vim / etc/php.ini
Modify the following
Session.save_path = "/ var/lib/php/session"
two。 Change the grouping of all files in the / var/lib/php/session directory to nginx and nginx.
Mkdir-p / var/lib/php/session
Chown-R nginx:nginx / var/lib/php/session
Install and configure WordPress1 to download WordPress, which can be downloaded from the official website
Https://zh-cn.wordpress.com/
two。 Delete the index.html file in the root directory of the website first
Rm / usr/share/nginx/html/index.html
3. Download WordPress and extract it to the current directory
Wget https://cn.wordpress.org/wordpress-5.2.3-zh_CN.tar.gz
Tar zxvf wordpress-5.2.3-zh_CN.tar.gz
Install the mysql database
You can refer to the method of installing mysql with yum in https://blog.51cto.com/13760351/2466032
Configure database 1.mysql-uroot-p # login database 2. Create a database
CREATE DATABASE wordpress
3. Create a new user
CREATE USER user@localhost
# 4. And set a password for this user
SET PASSWORD FOR user@localhost=PASSWORD ("wordpresspassword")
# 5. Give the created user full access to the database "wordpress".
GRANT ALL PRIVILEGES ON wordpress.* TO user@localhost IDENTIFIED BY 'wordpresspassword'
6. Refresh permissions.
FLUSH PRIVILEGES
7. Write database information
Create a new configuration file and copy the wp-config-sample.php file to a file named wp-config.php
Cd wordpress/
Cp wp-config-sample.php wp-config.php
8. Open and edit the newly created configuration file. Vim wp-config.php// * * MySQL settings-specific information comes from the name of the host you are using * * / / * * WordPress database name * / define ('DB_NAME',' wordpress'); / * MySQL database user name * / define ('DB_USER',' wordpress'); / * MySQL database password * / define ('DB_PASSWORD',' wordpresspasswd') / * * MySQL host * / define ('DB_HOST',' 112.3.122.114 DB_HOST', 3306'); / * * default text encoding when creating a data table * / define ('DB_CHARSET',' utf8'); / * * database collation type. If you are not sure, do not change * / define ('DB_COLLATE','); install WordPress1. Move the installation file to the Web server document root so that you can run the installation script to complete the installation.
Mv * / usr/share/nginx/html/
two。 Access the WordPress installation file in the browser
Http://192.168.65.193/
3. Fill in the installation as prompted
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.