yan-k
11/16/2016 - 4:10 PM

Change "Select an Option" to Select <attribute name>

Change "Select an Option" to Select

<?php

add_filter( 'woocommerce_dropdown_variation_attribute_options_args', 'yanco_wc_filter_dropdown_args', 10 );
function yanco_wc_filter_dropdown_args( $args ) {
    $variation_tax = get_taxonomy( $args['attribute'] );

	if( $variation_tax ) {
		$args['show_option_none'] = 'Choose your ' . apply_filters( 'the_title', $variation_tax->labels->name );
	} else {
		$args['show_option_none'] = 'Choose your ' . $args['attribute'];
	}

    return $args;
}