{"id":6255,"date":"2020-10-26T10:23:17","date_gmt":"2020-10-26T09:23:17","guid":{"rendered":"https:\/\/www.welaunch.io\/en\/?post_type=faq&p=6255"},"modified":"2023-02-17T13:17:16","modified_gmt":"2023-02-17T12:17:16","slug":"woocommerce-reward-points-shortcodes","status":"publish","type":"faq","link":"https:\/\/www.welaunch.io\/en\/knowledge-base\/faq\/woocommerce-reward-points-shortcodes\/","title":{"rendered":"WooCommerce Reward Points Shortcodes"},"content":{"rendered":"

Our WooCommerce Reward Points plugin currently offers different shortcodes, that you can use inside your WordPress site.<\/p>\n

Point Redemption Form Shortcode
<\/strong>Use the shortcode below to show the redemption form for points on any page.<\/p>\n

[woocommerce_reward_points_redemption_form]<\/pre>\n

Custom Text
<\/strong>With the below text you can create any text that will use and replace the same variables as you know from the admin panel texts. So for example you can write a text like “Your current point balance is {{currentPoints}}”.<\/p>\n

[woocommerce_reward_points_text text=\"Your current point balance is {{currentPoints}}.\"]<\/pre>\n

Another example to show points earned for a product purchase would be:<\/p>\n

[woocommerce_reward_points_text text=\"Buy this product to earn {{pointsValue}} {{pointsEarnPurchaseValue}} {{pointsEarnPurchase}} {{pointsLabel}}. {{tooltipText}}\"]<\/pre>\n

Current Level
<\/strong>This will show the current user level badge and name.<\/p>\n

[woocommerce_reward_points_level badge=\"yes\" name=\"no\" text=\"\" width=\"100%\"]<\/pre>\n

Products, that can be purchased with points
<\/strong>To show products, that can be purchased with user points use the shortcode below. You have 2 parameters show all (yes or no) and count.<\/p>\n

[woocommerce_reward_points_products_points_needed show_all=\"no\" count=\"-1\"]<\/pre>\n","protected":false},"author":1,"featured_media":0,"menu_order":0,"comment_status":"open","ping_status":"closed","template":"","product_cat":[],"class_list":["post-6255","faq","type-faq","status-publish","hentry","faq_topics-reward-points"],"_links":{"self":[{"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/faq\/6255","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/faq"}],"about":[{"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/types\/faq"}],"author":[{"embeddable":true,"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/comments?post=6255"}],"version-history":[{"count":7,"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/faq\/6255\/revisions"}],"predecessor-version":[{"id":14223,"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/faq\/6255\/revisions\/14223"}],"wp:attachment":[{"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/media?parent=6255"}],"wp:term":[{"taxonomy":"product_cat","embeddable":true,"href":"https:\/\/www.welaunch.io\/en\/wp-json\/wp\/v2\/product_cat?post=6255"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}