wpgenie icon

add content to auction base page

wpgenie | PRO | 03/19/21 10:08:41 AM UTC (Edited) | 0 ⭐ | 1221 👁️ | Never ⏰ | []
PHP |

440 B

|

None

|

0 👍

/

0 👎

/* this code snippet should go to your child theme's functions.php file */
add_action('woocommerce_archive_description', 'wpgenie_custom_auction_page_content', 40);
 
function wpgenie_custom_auction_page_content(){
    if(get_query_var('auction_arhive') == TRUE ){
        if(!is_paged()){
            $post_data = get_post(wc_get_page_id('auction'));
            $the_content = apply_filters( 'the_content', $post_data->post_content ) ;
            echo $the_content;  
        }   
    }
}

Comments