This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function iconic_woo_my_account_order() { | |
$myorder = array( | |
'dashboard' => __( 'Account', 'woocommerce' ), | |
'edit-account' => __( 'Personal Info', 'woocommerce' ), | |
'orders' => __( 'Orders', 'woocommerce' ), | |
'subscriptions' => __( 'Subscriptions', 'woocommerce' ), | |
'edit-address' => __( 'Address', 'woocommerce' ), | |
'payment-methods' => __( 'Payment Methods', 'woocommerce' ), | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Iconic LV: remove default LV buttons as they are added manually in divi builder. | |
* | |
* @return void | |
*/ | |
function iconic_wlv_remove_default_lv_buttons() { | |
remove_action( 'woocommerce_single_product_summary', array( 'Iconic_WLV_Product', 'output_linked_variations' ), 25 ); | |
} | |
add_action( 'init', 'iconic_wlv_remove_default_lv_buttons' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'manage_edit-shop_order_columns', 'wps_add_payment_method_column', 20 ); | |
/** | |
* Add payment method column | |
*/ | |
function wps_add_payment_method_column( $columns ) { | |
$new_columns = array(); | |
foreach ( $columns as $column_name => $column_info ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'wp_footer', function() { | |
if ( WC()->cart->is_empty() ) { | |
echo '<style type="text/css">CLASS HERE{ display: none; }</style>'; | |
} | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Orderable. | |
* Modify 'Today' label. | |
* | |
*/ | |
function change_delivery_today_text( $translated_text, $text, $domain ) { | |
switch ( $translated_text ) { | |
case 'Today' : | |
$translated_text = __( 'Add Text Here', 'woocommerce' ); | |
break; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
*Iconic Attributes Swatches - dequeue flickity JS and CSS | |
*/ | |
function iconic_was_dequeue_flickity(){ | |
wp_dequeue_style( 'flickity' ); | |
wp_dequeue_script( 'flickity' ); | |
} | |
add_action( 'wp_enqueue_scripts','iconic_was_dequeue_flickity', 11); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Show parent's short description for variations. | |
* | |
* @param string $excerpt | |
* @param $post | |
* | |
* @return string | |
*/ | |
function iconic_get_the_excerpt( $excerpt, $post ) { | |
if ( 'product_variation' !== $post->post_type ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Iconic WDS. | |
* Modify 'ASAP' label. | |
* | |
* @param string $label Label. | |
* | |
* @return string | |
*/ | |
function iconic_wds_modify_asap_label( $label ) { | |
return 'As soon as possible'; // Change this value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add Iconic linked products to shop page | |
add_filter('woocommerce_loop_add_to_cart_link', 'wlv_add_swatch', 999); | |
function wlv_add_swatch() { | |
echo do_shortcode('[iconic_wlv_links]'); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jQuery('.iconic-woothumbs-responsive-media video').attr('controls',true); |