Categories
Categories

Shortcodes

Solid Affiliate shortcodes
Last updated on February 15, 2023

Affiliate portal shortcode

Solid Affiliate comes with a collection of shortcodes to give you control over the Affiliate Portal components.

Solid Affiliate comes with an automatic way to create a page and embed the [solid_affiliate_portal] shortcode during the setup wizard. You can use these shortcodes on any page of your site, as many times as necessary to accomplish your goal.

Overview Video

We recommend watching this video recorded by our team which walks you through the shortcodes and shows you a live example use case. By the end of the video you’ll know everything you need to know.

[solid_affiliate_portal]

The [solid_affiliate_portal] shortcode renders the entire Affiliate Portal, including the registration form and affiliate login form unless you edit the Affiliate Portal settings. You must use this shortcode somewhere to render the affiliate portal. You can disable the login and registration forms from rendering via this shortcode in Affiliate Portal settings, and then use the below shortcodes for fine-grained control.

Note: This shortcode also takes an affiliate_group_id parameter. Setting this will cause any affiliates who register through the form to be assigned to the respective affiliate group. You must ensure that the ID is correct and that the group exists. Example [solid_affiliate_portal affiliate_group_id="3"]

[solid_affiliate_portal_login]

The [solid_affiliate_portal_login] shortcode renders just the Affiliate Portal login form.

[solid_affiliate_portal_registration]

The [solid_affiliate_portal_registration] shortcode renders just the Affiliate Portal registration form.

Note: This short-code also takes an affiliate_group_id parameter. Setting this will cause any affiliates who register through the form to be assigned to the respective affiliate group. You must ensure that the ID is correct and that the group exists. Example [solid_affiliate_portal_registration affiliate_group_id="3"]

[solid_affiliate_if_referred_by_affiliate ]

To conditionally display something to a visitor if they have been referred by an affiliate, you can use the [solid_affiliate_if_referred_by_affiliate] shortcode. This shortcode also takes an field parameter to conditionally show the current referring affiliate’s full name, or their username.

  • [solid_affiliate_current_affiliate field="fullname"] displays display the affiliate’s fullname.
  • [solid_affiliate_current_affiliate field="username"] displays the affiliate’s username.

Example of conditional rendering

[solid_affiliate_if_referred_by_affiliate ]
You’re shopping with [solid_affiliate_current_affiliate field="fullname"]!
[/solid_affiliate_if_referred_by_affiliate]

[solid_affiliate_current_affiliate_link]

Checks to see if the current user is an affiliate. If they are, it returns the default affiliate link for them. Otherwise, it returns an empty string.
Use case: “I would like to insert this shortcode on my site, and a link like this should appear: https://mydomain.com?sld=affiliateid