To connect Redis to Wordpress, you need to install the plugin - Redis Object Cache.
To do this , you need to go to the admin panel of your site - miysite.com/wp-admin, open the Plugins menu, add a new one:
Now you need to go to the hosting control panel https://cp.cityhost.ua/ , open Hosting 2.0. - Management - FTP - enter the file manager,
open the www folder, find the wp-config.php file in it, open the file and write the following lines:
'WP_REDIS_PATH' copy the line from the additional service section - Redis
'WP_CACHE_KEY_SALT' - you can write the name of the site for which caching is configured, or set a unique prefix for several sites.
An example of the arrangement of lines in the configuration file:
Now we return to the admin panel of the site , open the " Plugins" menu , find the desired plugin , click " Settings " :
In the settings , click " Enable object cache " :
If the setting is successful , we will see the following result :
Have a nice job!
All question categories