Skip to content

Instantly share code, notes, and snippets.

@jmabbas
jmabbas / functions.php
Last active January 29, 2026 09:48
MyTravel - Remove title on filter page
// Cargar título de categoría con etiqueta h1.
function mytravel_output_archive_wrapper() {
$sidebar = mytravel_get_archive_sidebar();
if ( ! class_exists( 'MAS_Travels' ) ) {
if ( is_product() ) {
$full_width_class = ' col-xl-9 mx-auto pb-5 pb-lg-0';
} else {
$full_width_class = ' col-lg-12 col-xl-12 order-1 order-lg-2 pb-5 pb-lg-0';
}
} else {
@jmabbas
jmabbas / functions.php
Created January 28, 2026 08:45
Vodi - Footer social icon style fix
function vodi_footer_top_bar_social() {
if ( has_nav_menu( 'social-media' ) ) :
wp_nav_menu( array(
'theme_location' => 'social-media',
'container_class' => 'footer-social-icons 123 social-label',
'menu_class' => 'social-icons',
'anchor_class' => 'footer-social-icon',
'depth' => 1,
'fallback_cb' => false,
'walker' => new Vodi_Social_Media_Navwalker(),
function mytravel_wc_product_page_title() {
$total = wc_get_loop_prop( 'total' );
if ( is_shop() || is_product_category() || is_tax( 'product_label' ) || is_tax( get_object_taxonomies( 'product' ) ) ) {
$page_title = woocommerce_page_title( false );
$title = str_replace( 'product-format-', '', $page_title );
} else {
$title = get_the_title();
}
?>
@jmabbas
jmabbas / style.css
Created January 16, 2026 09:27
Electro - Mobile icons color
.handheld-header-v2 .handheld-header-links>ul li>a::before,
.handheld-header-v2 .handheld-header-links i,
button.navbar-toggler.navbar-toggle-hamburger i {
color: #fff;
}
@jmabbas
jmabbas / functions.php
Created January 14, 2026 11:11
MyTravel - Product title h2 to h3
function woocommerce_template_loop_product_title() {
echo '<h3 class="' . esc_attr( apply_filters( 'woocommerce_product_loop_title_classes', 'woocommerce-loop-product__title' ) ) . '">' . get_the_title() . '</h3>'; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
}
@jmabbas
jmabbas / style.css
Created January 12, 2026 07:41
Electro - Custom styles
@media (max-width: 767.98px) {
.deal-products-carousel {
margin-bottom: 0;
padding-bottom: 10px;
}
}
@jmabbas
jmabbas / functions.php
Created January 9, 2026 12:27
Mytravel - category page Category title on h1 tag
function mytravel_output_archive_wrapper() {
$sidebar = mytravel_get_archive_sidebar();
if ( ! class_exists( 'MAS_Travels' ) ) {
if ( is_product() ) {
$full_width_class = ' col-xl-9 mx-auto pb-5 pb-lg-0';
} else {
$full_width_class = ' col-lg-12 col-xl-12 order-1 order-lg-2 pb-5 pb-lg-0';
}
} else {
$full_width_class = ' col-lg-12 col-xl-12 order-1 order-lg-2 pb-5 pb-lg-0';
@jmabbas
jmabbas / functions.php
Created January 9, 2026 07:07
Cartzilla - Move WooCommerce notice after main
add_action( 'after_setup_theme', function() {
remove_action( 'cartzilla_footer_after', 'woocommerce_output_all_notices', 100 );
add_action( 'cartzilla_footer_before', 'woocommerce_output_all_notices', 100 );
});
@jmabbas
jmabbas / style.css
Created January 9, 2026 05:50
Freshcart - custom
ul.wp-block-navigation__submenu-container.has-text-color.has-secondary-color.has-background.has-white-background-color.wp-block-navigation-submenu > li {
border-radius: 10px;
}
header .wp-block-group.navigation-bar.has-global-padding.is-layout-constrained.wp-block-group-is-layout-constrained {
position: static;
}
@jmabbas
jmabbas / functions.php
Created January 6, 2026 14:10
Electro - Home v5 category block order
add_filter( 'get_terms', 'electro_preserve_category_slug_order', 10, 4 );
function electro_preserve_category_slug_order( $terms, $taxonomies, $args, $term_query ) {
if (
is_admin()
|| empty( $args['include'] )
|| ! in_array( 'product_cat', (array) $taxonomies, true )
) {
return $terms;
}