MainWP Community

Useful Code Snippets for the ShortPixel Image Optimizer

Originally published at: https://mainwp.com/useful-code-snippets-for-the-shortpixel-image-optimizer/

ShortPixel is a well-used plugin for image optimization on sites. The plugin includes a number of filters and constants. You can hide your ShortPixel API key from the plugin’s settings by defining the API key in a constant in the sites wp-config.php file. Replace out the APIKEY with your actual API key for ShortPixel. define(‘SHORTPIXEL_API_KEY’,…

1 Like