As we all know, WordPress has always been the preferred program to build a blog, and now there are more and more enterprise sites are chosen to use WordPress to build.
WordPress is good but its too bloated and slow response to the shortcomings of the webmaster has been criticized, the online introduction for the WordPress accelerated method of various, each has its advantages and disadvantages.
And I chose to be through WP Super cache and seven cows combined for WordPress acceleration.
First ~
Before entering the subject, it is necessary and new to enter the pit of children's shoes under the following content:
Whether you have successfully installed WordPress on your local or server, you will find that it is very slow to open in the background because:
① backstage Use Gravatar avatar, that is the top right corner of the user avatar, and this provides this Avatar Service Web server is very unstable, and sometimes directly by the wall, so the background has been loading that avatar, causing the background open very slow
② backstage use of Google fonts, because Google has already moved away from China, so of course, has been loading
The most straightforward workaround for the above two reasons for slowing down our backstage is to replace and disable the feature.
/Online There are many plugins and tutorials to replace or disable Gravatar avatar, I have not one by one tested, so which plugin or tutorial effect is not good to jump to conclusions, I am currently using a modified avatar plugin ~
But most of the plug-ins or tutorials are through the access to third-party avatar service providers to solve this problem, such as I use this plugin is the Gravatar avatar to the address of the Geek family avatar services.
/While disabling Google Fonts is also very simple, directly in the background search installation ' Disable Google Fonts ' This plugin can be disabled with one click.
Next into the topic ~ First is WP Super Cache
WP Super cache is the domestic use of the most user WP static cache plug-in, in the background search for direct installation.
After successful installation, go to the Setup screen and select "Enable caching (recommended)"
Then go to ' advanced ', on this page except tick ' mod_rewrite cache mode ', the other options are only the recommended
After checking the recommended options, drop-down page to find mod rewrite rules, click Update.
Then refresh the homepage of the site to see the first page of the source code at the bottom of the following code, if any, has been set up successfully and has taken effect.
If the code is displayed as follows, it is not a setup failure, but does not provide a static cache for the currently logged-in user, and the above code will be displayed when the first page is refreshed after exiting the login.
In addition, you can also direct background search to install a Web compression plug-in autoptimize to cooperate with WP Super cache, and further speed up the website opening. You need to tick ' optimize HTML code and optimize CSS code ' when setting autoptimize, and other options will remain the default. In order to avoid some themes incompatible, the optimization JS This option is not checked.
The next to seven cattle ~
We all know that the picture is affecting a page loading speed is a factor, if the picture too much too much to cause the page loading too slow or incomplete loading, it will affect the user's browsing experience. And seven cattle can help us to solve this problem, we can put the image/download files on our website and even CSS and JS these static files to seven cows, while the seven cattle across the domestic CDN Accelerator node will also be for these static files accelerated.
First go to the official website to register and certification of a seven cow account, you can get free 10G space and monthly 10G traffic, for the small start-up site is enough.
Login Seven Cattle management background you will see the following interface, choose to add object storage.
Then fill in the space name, storage area and access control, note the access control to select ' Public space '
Click to confirm the creation of a successful creation of a storage space, seven will automatically assign a three-level domain name, but seven cattle also shows that this three-level domain name is only for testing, so in order to ensure the stability of our resources outside the chain, or it is recommended to bind the custom domain name.
Binding the custom domain name needs to recharge 10 yuan to seven cattle account first, and the bound domain name must be filed through ICP. After setting up a custom domain name, you need to wait for seven kn for approval before it takes effect.
After the audit passed to the domain name management to set up CNAME alias resolution, the custom domain name (usually the site's two-level domain name) to seven cattle to provide the domain name, while the seven cattle stored in the default address of the chain from the seven cattle to the three level of the domain name replaced by a custom domain.
At the same time set the ' mirror storage ' to achieve real-time synchronization of the site with seven of cattle static files. The image source fills in the domain name of the website, others keep the default
In order to reduce the unnecessary loss of seven KN flow, it is strongly recommended to set up the anti-theft chain to avoid the loss of 10G traffic per month due to the hotlinking of the person.
At this point, in the seven cow on the setup is basically completed, the rest is to be in our WordPress background bound seven cattle accelerated domain name.
WP webmaster all know for the load speed and stability of the website, should be as few as possible to install plug-ins, can not plug the place as far as possible without plug-ins, so adhering to this purpose, we do not need seven of the WP plug-in, because in WP Super cache can be directly set.
Go to WP Super Cache CDN interface, select ' Turn on CDN Support ', fill in the off-site URL one entry in the seven cow bound custom domain name, the following three items remain the default, and finally check the ' Ignore HTTPS ' option. Complete ~
Through the above configuration can be through the WP Super cache and seven cattle to speed up our WordPress website ~
Transferred from: HTTP://WWW.JIANSHU.COM/P/B5B11C40E9D4
With WP Super cache and seven kn for your WordPress website acceleration