title: Display member discounted prices to non-members in WooCommerce
body: <p>In WooCommerce, I have 3 membership tiers (silver, gold and platinum) and I applied higher discount rate for higher membership tier.</p>
  
  <p>I would like show the 4 different prices (non-member, silver, gold and platinum) to everyone such that they know how much they can save on each product if they join the membership. For example: <br></p>
  
  <ul>
  <li>Regular Price: $100</li>
  <li>Silver Member: $90</li>
  <li>Gold Member: $80</li>
  <li>Platinum Member: $70</li>
  </ul>
  
  <p>I tried <a href="https://wpquestions.com/Display_member_pricing_to_a_non_member_in_woocommerce_memberships/27590" rel="nofollow noreferrer">the code below</a>:</p>
  
  <pre><code>function bsc_wc_memberships_members_only_product_price() {
      global $product;
  
      $user = wp_get_current_user();
  
      if ( !wc_memberships_is_user_active_member($user-&gt;ID, 'test') ) {
  
          $id = $product-&gt;get_id();
          $discount = get_post_meta( $id, 'member_price', true );
          $price = $product-&gt;get_price();
  
          echo 'Member price: $'.$total = $price - $discount;
      }
  
  }
  add_action( 'woocommerce_before_add_to_cart_button', 'bsc_wc_memberships_members_only_product_price' );
  </code></pre>
  
  <p>But it doesn't really work unfortunately... Any advice will be highly appreciated.</p>