Used by the Point for referrals hook, this shortcode will append the current users referral link to a given URL. If no URL is given, the current page’s URL is used.
||string||No||-||A specific URL that we want to append the referral code to. If not used or left empty, the URL of the page where the shortcode is used will be used.|
||string||No||mycred_default||If you are using multiple point types and the hook is enabled for more then one type, you can use this to define which point type this shortcode belongs to.|
This shortcode does not return any stylable elements.
Example 1: Use the shortcode to present the current page’s URL that users need to use in order to get points for referrals.
Earn points by sharing this page. Copy and paste the following URL: [mycred_affiliate_link]
Example 2: Use the shortcode to present a specific URL that users need to use in order to get points for referrals.
Earn points by sharing. Copy and paste the following URL: [mycred_affiliate_link url="http://www.merovingi.com"]
Example 3: Append the referral link directly into an anchor element.
<a href="[mycred_affiliate_link]">Click on this referral link</a>