Skip to content

Instantly share code, notes, and snippets.

View orenshim's full-sized avatar

Oren Shimon orenshim

View GitHub Profile
add_filter('add_to_cart_redirect', 'cw_redirect_add_to_cart');
function cw_redirect_add_to_cart() {
global $woocommerce;
$cw_redirect_url_checkout = $woocommerce->cart->get_checkout_url();
return $cw_redirect_url_checkout;
}
add_filter( 'woocommerce_product_single_add_to_cart_text', 'cw_btntext_cart' );
add_filter( 'woocommerce_product_add_to_cart_text', 'cw_btntext_cart' );
function cw_btntext_cart() {
return __( 'Go To Checkout', 'woocommerce' );
}
@orenshim
orenshim / gist:552117a006b093b5749afe0b4589625a
Created May 1, 2019 06:18
Custom CSS to fix Elementor columns gap issue
/* Make Elementor elements expand to fit the full available width - due to how EL puts padding
all the way round columns */
.elementor-section-boxed .elementor-column-gap-default > .elementor-row {
width: calc(100% + 20px);
margin-left: -10px;
margin-right: -10px;
}
.elementor-section-boxed .elementor-column-gap-narrow > .elementor-row {
width: calc(100% + 10px);
margin-left: -5px;
@orenshim
orenshim / gist:1332e26a691734d672be3e9aa5bfbcca
Created November 21, 2018 10:20
css for space after pharagrph
line-height: 25px; /* within paragraph */
margin-bottom: 20px; /* between paragraphs */
}