Skip to content

Commit

Permalink
Merge pull request #46 from skyverge/mwc-4559/remove-placeholder-imag…
Browse files Browse the repository at this point in the history
…e-setting

Removes image placeholder setting
  • Loading branch information
unfulvio authored Mar 2, 2022
2 parents c0ad2a4 + 990c594 commit 1dd8933
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 24 deletions.
14 changes: 0 additions & 14 deletions includes/class-wc-customizer-settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -416,20 +416,6 @@ public function get_settings() {

array( 'type' => 'sectionend' ),

array(
'title' => __( 'Images', 'woocommerce-customizer' ),
'type' => 'title'
),

array(
'id' => 'woocommerce_placeholder_img_src',
'title' => __( 'Placeholder Image source', 'woocommerce-customizer' ),
'desc_tip' => __( 'Change the default placeholder image by setting this to a valid image URL', 'woocommerce-customizer' ),
'type' => 'text'
),

array( 'type' => 'sectionend' ),

),
);

Expand Down
5 changes: 4 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&business=paypal@s
Tags: woocommerce, woocommerce shop, woocommerce filters, woocommerce text
Requires at least: 4.7
Tested up to: 5.9.1
Stable tag: 2.7.5
Stable tag: 2.7.6-dev.1
License: GPLv3 or later
License URI: http://www.gnu.org/licenses/gpl-3.0.html

Expand Down Expand Up @@ -71,6 +71,9 @@ Of course! Please fork the [GitHub](https://github.com/skyverge/woocommerce-cust

== Changelog ==

= 2022.nn.nn - version 2.7.6-dev.1 =
* Fix - Remove image placeholder (this is included in WC 3.5+)

= 2022.03.01 - version 2.7.5 =
* Misc - Require WooCommerce 3.9.4 or newer

Expand Down
11 changes: 2 additions & 9 deletions woocommerce-customizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* Description: Customize WooCommerce without code! Easily change add to cart button text and more.
* Author: SkyVerge
* Author URI: http://www.skyverge.com
* Version: 2.7.5
* Version: 2.7.6-dev.1
* Text Domain: woocommerce-customizer
* Domain Path: /i18n/languages/
*
Expand Down Expand Up @@ -46,7 +46,7 @@ class WC_Customizer {


/** plugin version number */
const VERSION = '2.7.5';
const VERSION = '2.7.6-dev.1';

/** required WooCommerce version number */
const MIN_WOOCOMMERCE_VERSION = '3.9.4';
Expand Down Expand Up @@ -169,13 +169,6 @@ public function load_customizations() {
add_filter( 'woocommerce_product_add_to_cart_text', array( $this, 'customize_add_to_cart_text' ), 50, 2 );
}

} elseif ( 'woocommerce_placeholder_img_src' === $filter_name ) {

// only filter placeholder images on the frontend
if ( ! is_admin() ) {
add_filter( $filter_name, array( $this, 'customize' ), 50 );
}

} elseif ( 'loop_sale_flash_text' === $filter_name || 'single_sale_flash_text' === $filter_name ) {

add_filter( 'woocommerce_sale_flash', array( $this, 'customize_woocommerce_sale_flash' ), 50, 3 );
Expand Down

0 comments on commit 1dd8933

Please sign in to comment.