Show Product SKU on Shop Page.

Home Page Forums Porto | Multi-Purpose & WooCommerce Theme Show Product SKU on Shop Page.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #746
    Lodrigo Jan
    Participant
        Expired

        Hi.

        Is it possible to display the Product SKU on the Shop Page?
        I want to show SKU on each product type.

        Thanks.

        #747
        Alex
        Keymaster
            Expired

            Hello.

            Please copy and paste the below given code to the functions.php file in Child Theme and it will resolve your issue.

            
            add_action( 'woocommerce_after_shop_loop_item_title', 'custom_after_title' );
            function custom_after_title() {
              global $product;
              if ( $product->get_sku() ) {
                echo $product->get_sku();
              }
            }
            

            Regards, from Andy.

          Viewing 2 posts - 1 through 2 (of 2 total)
          • The topic ‘Show Product SKU on Shop Page.’ is closed to new replies.
          Customize Icon
          Need Customization? We specialize in delivering high-quality web and mobile design/development services to our clientele. Should you require customization services, please do not hesitate to reach out to us at your convenience.