-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from smithfield-studio/update-2-4-3
- Loading branch information
Showing
25 changed files
with
526 additions
and
417 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.DS_Store |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
# Kinsta Must Use (MU) Plugin | ||
|
||
A simple mirror of the official Kinsta Mu Plugin with added Composer/[Bedrock](https://github.com/roots/bedrock) support. | ||
|
||
For latest version/info please see the official [Kinsta MU Plugin page](https://kinsta.com/help/kinsta-mu-plugin/). | ||
|
||
## Installing with Composer (for Bedrock) | ||
|
||
1. Add this plugin repo to `repositories`in your Bedrock `composer.json` file: | ||
```diff | ||
"repositories": { | ||
"wpackagist": { | ||
"type": "composer", | ||
"url": "https://wpackagist.org", | ||
"only": [ | ||
"wpackagist-plugin/*", | ||
"wpackagist-theme/*" | ||
] | ||
}, | ||
+ "kinsta-mu-plugins": { | ||
+ "type": "vcs", | ||
+ "url": "[email protected]:retlehs/kinsta-mu-plugins" | ||
+ }, | ||
``` | ||
1. Add the plugin requirement with specific version number (or `*` for latest) to `composer.json`: | ||
```diff | ||
"require": { | ||
"php": ">=7.4", | ||
"composer/installers": "^2.0", | ||
... | ||
+ "kinsta/kinsta-mu-plugins": "*", | ||
... | ||
} | ||
``` | ||
1. Run `composer update` from the Bedrock directory. | ||
|
||
|
||
## White label | ||
|
||
Enabling white labeling will change the following elements in the WordPress dashboard: | ||
|
||
1. The branded **Kinsta Cache** sidebar link will be changed to an unbranded **Cache Settings** link. | ||
1. The **Thanks for creating with WordPress and hosting with Kinsta** message near the bottom of the dashboard will be replaced with **Thank you for creating with WordPress**. | ||
1. The Kinsta logo on the **Cache Control** page will be removed or replaced with an image of your choice. | ||
1. The links to Kinsta documentation and support will be removed. | ||
|
||
```php | ||
define('KINSTAMU_WHITELABEL', true); | ||
define('KINSTAMU_LOGO', 'https://mylogo.com/mylogo.jpg'); | ||
``` | ||
|
||
For more info, refer to the [official docs here](https://kinsta.com/help/white-label-kinsta-wordpress-admin/) | ||
|
||
|
||
## Bedrock + Kinsta | ||
The following constants may be required to fix issues with CDN paths + shared plugin asset URLs. | ||
|
||
```php | ||
/** | ||
* Kinsta CDN fix for Bedrock | ||
*/ | ||
define('KINSTA_CDN_USERDIRS', 'app'); | ||
|
||
/** | ||
* Fix Kinsta MU Plugins URL path with Bedrock | ||
*/ | ||
$mu_plugins_url = Config::get('WP_CONTENT_URL') . '/mu-plugins'; | ||
define('KINSTAMU_CUSTOM_MUPLUGIN_URL', "{$mu_plugins_url}/kinsta-mu-plugins"); | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -63,10 +63,10 @@ | |
<?php | ||
echo wp_kses( | ||
$warning_msg, | ||
[ | ||
array( | ||
'strong' => true, | ||
'code' => true, | ||
] | ||
) | ||
); | ||
?> | ||
</div> | ||
|
Oops, something went wrong.