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
/** | |
* WooCommerce Quanity buttons add-back | |
*/ | |
jQuery( function( $ ) { | |
var $testProp = $( 'div.quantity:not(.buttons_added), td.quantity:not(.buttons_added)' ).find('qty'); | |
if ($testProp && $testProp.prop('type') != 'date') { | |
// Quantity buttons | |
$( 'div.quantity:not(.buttons_added), td.quantity:not(.buttons_added)' ).addClass( 'buttons_added' ).append( '<input type="button" value="+" class="plus" />' ).prepend( '<input type="button" value="-" class="minus" />' ); | |
// Target quantity inputs on product pages |
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
<?php | |
#hook into wordpress wp_head | |
add_action('wp_head','wpfh_custom_share_button_scripts'); | |
#hook into above tabs in funeralpress | |
add_action('wpfh/obituary/above_tabs','wpfh_custom_share_button',10,2); | |
function wpfh_custom_share_button_scripts(){ |
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
<?php | |
#Read article here https://worcesterwideweb.com/woocommerce-add-single-product-notice-on-a-per-category-basis-with-hierarchy/ | |
add_filter( 'the_content', 'customizing_woocommerce_description' ); | |
function customizing_woocommerce_description( $content ) { | |
global $post; | |
// Only for single product pages (woocommerce) | |
if ( is_product() ) { | |
# get the terms for this post | |
$terms = get_the_terms( $post->ID, 'product_cat' ); |