Skip to content

Instantly share code, notes, and snippets.

@jmabbas
jmabbas / functions.php
Created May 7, 2025 11:24
GoTrek - Show Room Information
function gotrek_room_info( $id ) {
$product = wc_get_product( $id );
if ( ! $product ) {
return;
}
$product_name = $product->get_name(); // Get the product/room name.
$price_html = $product->get_price_html(); // Get the formatted price HTML.
@jmabbas
jmabbas / style.css
Created May 7, 2025 07:25
Pizzaro - Movie description title plus icon remove
.single-movie-v6 h2.single-movie-details--description__title:after,
.single-movie-v7 h2.single-movie-details--description__title:after {
display: none;
}
@jmabbas
jmabbas / functions.php
Created May 6, 2025 08:43
Vodi - Display label if movies Empty
function masvideos_template_single_movie_player_wrap_open() {
ob_start(); // Start output buffering
masvideos_the_movie();
$output = ob_get_clean(); // Get the output
if (!empty($output)) {
?>
<div class="movie__player">
<?php
@jmabbas
jmabbas / functions.php
Created May 1, 2025 08:05
Finder - functions
function finder_sidebar_button() {
?>
<button class="btn btn-primary btn-sm w-100 rounded-0 fixed-bottom d-lg-none" type="button" data-bs-toggle="offcanvas" data-bs-target="#blog-sidebar">
<i class="fi-sidebar-right me-2"></i><?php echo esc_html('Sidebar') ?>
</button>
<?php
}
function finder_hivepress_category_filter_dropdown() {
$taxonomy = 'hp_listing_category';
@jmabbas
jmabbas / functions.php
Last active April 29, 2025 12:57
Bookworm - Brand image on Single product page
function bookworm_wc_single_product_author() {
global $product;
$product_id = $product->get_id();
$brands_tax = bookworm_get_book_author_taxonomy();
$terms = get_the_terms( $product_id, $brands_tax );
$brand_html = '';
@jmabbas
jmabbas / text.html
Created April 23, 2025 07:16
Front - Team block html
<div class="team-member-block space-2 space-md-3 container false">
<div class="w-md-80 text-center mx-md-auto mb-9 w-lg-50">
<span class="btn btn-xs btn-pill mb-2 btn-soft-success">Our Team</span>
<h2 class="font-weight-normal">Trust the professionals</h2>
<p>Our top professionals are ready to help with your business 123</p>
</div>
<div class="fgb-team-member mb-5 row">
<div class="col-sm-6 col-lg-3">
<div class="fgb-team-member__item card p-0 border-0 shadow-none transition-3d-hover">
<div class="fgb-team-member__image img-fluid w-100 rounded fgb-team-member__image--basic ugb-image-upload-placeholder ugb-image-upload-has-image" role="button" tabindex="0" data-is-placeholder-visible="false">
@jmabbas
jmabbas / style.css
Created March 29, 2025 10:55
Electro - YITH Heart icon Dark style
a.yith-wcwl-add-to-wishlist-button {
font-size: 13px;
align-items: flex-start !important;
gap: 3px !important;
}
a.yith-wcwl-add-to-wishlist-button svg {
width: 17px !important;
height: 17px;
}
@jmabbas
jmabbas / functions.php
Created March 26, 2025 10:33
Electro Custom content between header and topbar
add_action( 'electro_before_header', 'custom_header_content', 15 );
function custom_header_content() { ?>
<div class="container">
cusotm content
</div>
<?php
}
@jmabbas
jmabbas / functions.php
Created March 26, 2025 05:49
Silicon Offcanvas
function silicon_header_navbar_offcanvas() {
$header_class = silicon_custom_sticky_header_options();
$dark_css = strpos( $header_class, 'navbar-dark' ) ? ' bg-dark' : '';
?>
<div id="navbarNav" class="offcanvas offcanvas-end<?php echo esc_attr( $dark_css ); ?>">
<div class="offcanvas-header border-bottom">
<h5 class="offcanvas-title"><?php echo esc_html__( 'Menu', 'silicon' ); ?></h5>
<button type="button" class="btn-close" data-bs-dismiss="offcanvas" aria-label="Close"></button>
</div>
<div class="offcanvas-body">
@jmabbas
jmabbas / functions.php
Created March 21, 2025 12:14
Mytravel - Header account
function mytravel_header_navbar_account() {
$header_style = mytravel_get_header_style();
if ( mytravel_header_signin_enable() ) {
$myt_page_options = array();
if ( function_exists( 'mytravel_option_enabled_post_types' ) && is_singular( mytravel_option_enabled_post_types() ) ) {
$clean_meta_data = get_post_meta( get_the_ID(), '_myt_page_options', true );
$_myt_page_options = maybe_unserialize( $clean_meta_data );