The Referral Element shows an individual referral campaign promotion. This includes interactive elements to allow the user to make a referral, according to the campaign rules.
To include a Referral Campaign Element on a webpage do the following:
- Add the following script tags at the top of the page
<script type="module" src="https://elements.spaaza.com/elem/spaaza-environment.js"></script> <script type="module" src="https://elements.spaaza.com/elem/spaaza-referral-campaign.js"></script>
- Add the Environment tag to the contents of the page (below the script tags). Include the Referral Campaign within the Environment tag.
<spaaza-environment config="your_config_goes_here"> <spaaza-referral-campaign id="1234"></spaaza-referral-campaign> <!-- other Spaaza Elements and HTML goes here --> </spaaza-environment>
The following properties can be passed to the Referral Campaign Element.
|id (required)||The id of the referral campaign you want to show. You can find the id of the campaign in Spaaza Conssole when you view the referral campaign page.|