Please submit a private ticket if you need to share sensitive information, such as license details and admin credentials.

Okay
  Public Ticket #2875143
Variations Title
Closed

Comments

  • Malik Arslan started the conversation

    Hi, Thanks for the awesome plugin: https://wordpress.org/plugins/wpc-show-single-variations/


    But it's missing a feature i was looking for.
    How to customize title of each variation? It just add attributes at the end of parent product.
    I want to customize title of each variation. This title should appear on the shop page and it should be dynamically changed on single product page whenever a person select a variation.

    Is it possible? Is there any way you can help me with?
    Looking forward to your response..
    Thanks

  •  767
    Janilyn replied

    Hi Malik,

    Thanks for contacting WPClever Support Forum. We're not available at the weekends so today (Monday) I am able to process your ticket.

    We’ve received your ticket and assigned one of our developers to help you with that. 

    He’ll be looking into your question and responding with specific instructions as soon as possible. 

    Please stay patient as we're having very heavy workloads, it might take some time for our developers to reach back.

    Best regards.

    Janilyn T. - WPClever Support Agent

  •  1,223
    Dustin replied

    Hi Malik,

    Yes, you can do that!

    Please also install another plugin from us https://wordpress.org/plugins/wpc-variations-radio-buttons/ then you can fill the custom name here https://www.screencast.com/t/5SJv15ppeuv3

    Then add the below custom code (How to add custom code?)

    add_filter( 'the_title', 'woosv_change_variation_name', 10, 2 );
    function woosv_change_variation_name( $title, $id = null ) {
        $prod = wc_get_product( $id );
        if ( $prod && $prod->is_type( 'variation' ) ) {
            if ( $woovr_name = get_post_meta( $id, 'woovr_name', true ) ) {
                return $woovr_name;
            }
        }
        return $title;
    }

    And the result https://www.screencast.com/t/QXBzDz2U60

    Best regards,
    Dustin