HEX
Server: Apache
System: Linux webm020.cluster127.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64
User: bohousj (181416)
PHP: 8.4.22
Disabled: _dyuweyrj4,_dyuweyrj4r,dl
Upload Files
File: /home/bohousj/medal/wp-content/themes/choicy/inc/layouts/choicy-actions.php
<?php

/**
 *
 * choicy header
 */
function choicy_check_header() {
    $id = get_the_ID();

    if ( get_option( 'page_for_posts' ) ) {
        $id = get_the_ID();
    }
    if ( CHOICY_WOOCOMMERCE_ACTIVED && is_shop() ) {
        $id = get_option( 'woocommerce_shop_page_id' );
    }
    $header_meta = get_post_meta( $id, 'tx_page_meta', true ) ? get_post_meta( $id, 'tx_page_meta', true ) : [];
    $page_header_disable = array_key_exists( 'page_header_disable', $header_meta ) ? $header_meta['page_header_disable'] : false;

    if ( $page_header_disable != true ) {
        Choicy_Helper::choicy_header_template();
    }

}
add_action( 'choicy_header_style', 'choicy_check_header', 10 );

/**
 *
 * choicy footer
 */
function choicy_check_footer() {
    $id = get_the_ID();

    if ( get_option( 'page_for_posts' ) ) {
        $id = get_the_ID();
    }
    if ( CHOICY_WOOCOMMERCE_ACTIVED && is_shop() ) {
        $id = get_option( 'woocommerce_shop_page_id' );
    }

    $footer_meta = get_post_meta( $id, 'tx_page_meta', true ) ? get_post_meta( $id, 'tx_page_meta', true ) : [];
    $page_footer_disable = array_key_exists( 'page_footer_disable', $footer_meta ) ? $footer_meta['page_footer_disable'] : false;

    if ( $page_footer_disable != true ) {
        Choicy_Helper::choicy_footer_template();
    }
}
add_action( 'choicy_footer_style', 'choicy_check_footer', 10 );

// favicon logo
function choicy_favicon_logo_func() {
    $choicy_favicon = cs_get_option( 'tx_favicon', get_template_directory_uri() . '/assets/img/favicon.webp');
    if(isset($choicy_favicon['url'])) {
        $choicy_favicon_url = $choicy_favicon['url'];
    } else {
        $choicy_favicon_url = get_template_directory_uri() . '/assets/img/favicon.webp';
    }
?>
<link rel="shortcut icon" type="image/x-icon" href="<?php print esc_url( $choicy_favicon_url );?>">
<?php
}
add_action( 'wp_head', 'choicy_favicon_logo_func' );