Additional Labels on Product Image - by mipromo

This topic has 13 replies, 4 voices, and was last updated 8 years, 11 months ago ago by Eva Kemp

  • Avatar: mipromo
    mipromo
    Participant
    November 22, 2015 at 14:09

    Hello,

    Currently I only have the option to place “NEW” when am adding a product. I have the option to use additional labels aside “NEW”

    How do I do this?

    BR

    Anthony

    12 Answers
    Avatar: Robert Hall
    Robert Hall
    Support staff
    November 23, 2015 at 11:26

    Hello,

    Navigate to Dashboard->Products->edit product->Additional Products options-> and select yes for ‘Mark product as “New”‘

    Regards,
    Robert Hall.

    Avatar: mipromo
    mipromo
    Participant
    November 24, 2015 at 06:54

    Hello Robert,

    Thanks for the reply. I know how to add “NEW” to the product image. What I need is how to implement the ability to add other labels such as “20% OFF”, “50% OFF” etc to the product image. We have a color tag sale which we run in our physical store and we wish to do same online.

    To be more specific in addition to the label “NEW”, we need the ability the place following labels aside “NEW” on the product image when adding or editing a product-
    Yellow label with 20% OFF as text
    Blue label with 30% OFF as text
    Green label with 40% OFF as text
    Red label with 50% OFF as text

    Thanks again.

    BR

    Anthony

    Avatar: Robert Hall
    Robert Hall
    Support staff
    November 24, 2015 at 08:24

    Hello,

    Unfortunately we don’t have such options.

    You can try to use some third-party plugin to implement such functionality.

    Regards,
    Robert Hall.

    Avatar: mipromo
    mipromo
    Participant
    November 24, 2015 at 11:49

    Thanks Robert for your quick response. Can’t the same process used in implementing “NEW” on the product image be replicated to implement the other labels?

    BR

    Anthony

    Avatar: Robert Hall
    Robert Hall
    Support staff
    November 24, 2015 at 11:53

    Also you can try to edit labels by yourself in \themes\woopress\woocommerce\loop\sale-flash.php file

    Regards,
    Robert Hall.

    Avatar: mipromo
    mipromo
    Participant
    November 24, 2015 at 14:31

    Thanks Robert. I have edited that. I have also edited the style sheet. What other file should I edit so that I can select the relevant label under Additional Product Options when adding a new product?

    Thanks again.

    Anthony

    Avatar: Brian Johnson
    Brian Johnson
    Member
    November 24, 2015 at 16:05

    Hello,

    You may edit 950 line in /themes/woopress/framework/woo.php.

    Regards,
    Brian Johnson

    Avatar: mipromo
    mipromo
    Participant
    November 24, 2015 at 16:57

    Hello Robert, I have edited as instructed by you. I still do not have the option to change the label from “NEW”

    BR

    Anthony

    Avatar: mipromo
    mipromo
    Participant
    November 24, 2015 at 17:00

    I added a second option based on the “NEW” code

    // **********************************************************************// 
    // ! Is product New
    // **********************************************************************// 
    
    if(!function_exists('etheme_product_is_new')) {
    	function etheme_product_is_new( $product_id = '' ) {
    		global $post, $wpdb;
    	    $key = 'product_new';
    		if(!$product_id) $product_id = $post->ID;
    		if(!$product_id) return false;
    	    $_etheme_new_label = get_post_meta($product_id, $key);
    	    if(isset($_etheme_new_label[0]) && $_etheme_new_label[0] == 'enable') {
    	        return true;
    	    }
    	    return false;	
    	}
    }
    
    // **********************************************************************// 
    // ! Is product Yellow
    // **********************************************************************// 
    
    if(!function_exists('etheme_product_is_yellow')) {
    	function etheme_product_is_yellow( $product_id = '' ) {
    		global $post, $wpdb;
    	    $key = 'product_yellow';
    		if(!$product_id) $product_id = $post->ID;
    		if(!$product_id) return false;
    	    $_etheme_yellow_label = get_post_meta($product_id, $key);
    	    if(isset($_etheme_yellow_label[0]) && $_etheme_yellow_label[0] == 'enable') {
    	        return true;
    	    }
    	    return false;	
    	}
    }
    
    Avatar: Eva
    Eva Kemp
    Support staff
    November 25, 2015 at 15:26

    Hello,

    To add label under Additional Product Options when editing a product you need modify the file wp-content/themes/woopress/framework/theme-options.php (from line 2258).

    Regards,
    Eva Kemp.

    Avatar: mipromo
    mipromo
    Participant
    November 25, 2015 at 20:21

    Thanks Eva, I have done that…it is showing on the backend but if I enable it, it does not show on the image.

    What am I missing here? Hope to hear from you soon.

    BR

    Anthony

    Avatar: Eva
    Eva Kemp
    Support staff
    November 25, 2015 at 21:17

    Hello,

    Please take our apologies but we don’t provide support for additional customizations, it’s out of our scope.

    Thank you for understanding.

    Regards,
    Eva Kemp.

  • Viewing 13 results - 1 through 13 (of 13 total)

You must be logged in to reply to this topic.Log in/Sign up

8theme customization service
We're using our own and third-party cookies to improve your experience and our website. Keep on browsing to accept our cookie policy.