← Back
Editing: class-wp-smush-pro-config.php
<?php namespace GD_cORe\handlers\plugin_configs; if ( ! defined( 'ABSPATH' ) ) { exit; } /** * The admin-specific functionality of the plugin. * * * @package GD_cORe * @subpackage GD_cORe/admin */ class wp_smush_pro extends Main { public $config = array( 'smushImageSizes' => array("thumbnail","medium","large","woocommerce_thumbnail","woocommerce_single","woocommerce_gallery_thumbnail","shop_catalog","shop_single","shop_thumbnail","medium_large","full" ), 'smushResizeSizes' => array("width" => 1920, "height" => 1080), 'smushSettings' => array( "auto" => 1, "lossy" => 1, "strip_exif" => 1, "resize" => 1, "detection" => 0, "original" => 1, "backup" => 0, "png_to_jpg" => 1, "nextgen" => 0, "gutenberg" => 0, "js_builder" => 0, "cdn" => 0, "auto_resize" => 0, "webp" => 1, "usage" => 1, "accessible_colors" => 0, "keep_data" => 1, "lazy_load" => 1, "background_images" => 1, "networkwide" => 0, 'webp_mod' => 1, ), 'smushLazySettings' => array( "format" => array( "jpeg" => 1, "png" => 1, "gif" => 1, "svg" => 1 ), "output" => array( "content" => 0, "widgets" => 0, "thumbnails" => 0, "gravatars" => 0 ), "animation" => array( "selected" => "0", "fadein" => array( "duration" => 0, "delay" => 0 ), "spinner" => array( "selected" => 1, "custom" => array(), ), "placeholder" => array( "selected" => 1, "custom" => array(), "color" => "#F3F3F3" ) ), "include" => array( "frontpage" => 1, "home" => 1, "page" => 1, "single" => 1, "archive" => 1, "category" => 1, "tag" => 1 ), "excluse-pages" => array(), "exclude-classes" => array(), "footer" => 0 ) ); public function __construct(){ } public function runConfig(){ update_option("wp-smush-settings", $this->config['smushSettings'], false); update_option("wp-smush-lazy_load", $this->config['smushLazySettings'], false); update_option("wp-smush-image_sizes", $this->config['smushImageSizes'], false); update_option("wp-smush-resize_sizes", $this->config['smushResizeSizes'], false); update_option("skip-smush-setup", 1, false); } }
Save File
Cancel