WordPress default is to use MySQL as a database support, this for the personal webmaster is still a bit of trouble. Especially if later site backup migration is a bit more.
Before using Django to develop their own blog feel in fact with Sqlite3 as a database inserted, is a file just. Back up your Web site and simply package your entire catalog to save hassle.
Then as a personal webmaster, if you want to use WordPress and Sqlite3 to build the site, how to do? Here in the Windows environment I tried it, and it was convenient. If it is a production environment, please install WordPress tutorial from Baidu Linux.
1. Preparation of work 1. Build PHP Runtime Environment (if you are small white, and Windows system, I recommend the use of Phpstudy, you can see my other share: 1. Build PHP Runtime Environment (if you are small white, and Windows system, I recommend the use of Phpstudy, you can see my other share: phpstudy2017 version of Nginx support Laravel 5.X configuration
1. Build PHP Runtime Environment (if you are a small white, and Windows system, I recommend the use of XAMPP)
2. Download WordPress
3. Download the SQLite Integration plugin
Unzip the downloaded WordPress tarball into any directory
4, Configuration Phpstudy Apache
<virtualhost *:80> documentroot "H:\code\blog" ServerName www.blog.com <directory "H : \code\blog "> Options Indexes followsymlinks execcgi allowoverride all Order allow,deny Require all granted </Directory></VirtualHost>
If it is nginx manually modify the nginx.conf file. Add a server to
1server {2 Listen 80;3server_name www.herostore.cn;4 set $root _path ' c:/laravel/';5Root $root _path;67Index index.php index.html index.htm;89 Location/{Try_files $uri $uri//index.php? $query _string;11}12Location ~ \.php (. *)$ {Fastcgi_pass 127.0.0.1:9000;15Fastcgi_index index.php;Fastcgi_split_path_info ^ (? U). +\.php) (/?. +)$;17Fastcgi_param script_filename $document _root$fastcgi_script_name;18 Fastcgi_param path_info $fastcgi _path_info; 19 Fastcgi_param path_translated $document _root$fastcgi _path_info; 20 include Fastcgi_params; }22 23 location ~* ^/(CSS |img|js|flv|swf|download)/(. +) $ {24 25 }26 27 Location ~/\.ht {28 deny All; }30}
5. Copy and paste the wp-config-sample.php under the directory to rename it to wp-config.php
Open wp-config.php Modify the following configuration
Original file:
* * MySQL Settings-specific information from the host you are using * *//
/** Name of WordPress database */
Define (' db_name ', ' database_name_here ');
/** MySQL Database user name */
Define (' Db_user ', ' username_here ');
/** MySQL Database password */
Define (' Db_password ', ' password_here ');
/** MySQL Host */
Define (' db_host ', ' localhost ');
/** The default text encoding when creating data tables */
Define (' Db_charset ', ' UTF8 ');
/** the database collation type. If you are unsure do not change */
Define (' db_collate ', ');
Modified to:
* * MySQL Settings-specific information from the host you are using * *//
/** Name of WordPress database */
Define (' db_name ', ' MyBlog ');//myblog<==== This is the name of the database and can be customized
/** MySQL Database user name */
Define (' Db_user ', ');
/** MySQL Database password */
Define (' Db_password ', ');
/** MySQL Host */
Define (' db_host ', ' localhost ');
/** The default text encoding when creating data tables */
Define (' Db_charset ', ' UTF8 ');
/** the database collation type. If you are unsure do not change */
Define (' db_collate ', ');
Define (' Wp_allow_repair ', true);//Database repair using
Define (' Db_type ', ' SQLite '); MySQL or SQLite '
Unzip the SQLite integration to the WordPress installation directory wp-content\plugins\
6. Find db.php
Copy to the Wp-content directory in the WordPress installation directory
7. Run and configure the blog to start your wordpress blog Tour
Example 4. Start your WordPress blog Tour default home page
Caring for single Dog Growth Association
Links: https://www.jianshu.com/p/59f4e3545bbd
Source: Pinterest
Copyright belongs to the author. Commercial reprint please contact the author for authorization, non-commercial reprint please specify the source.
How to get WordPress to build a lightweight blogging system with Sqlite3