Your WePlant Badge
1. Add this code to you website
<script>
window.addEventListener("load", function(){
var [script, id, js] = ["script", "weplant-js", ""];
var fjs = document.getElementsByTagName(script)[0];
if (!document.getElementById(id)) {
js = document.createElement(script);
js.id = id;
js.src = "https://widget.forestnation.com/widget.min.js";
fjs.parentNode.insertBefore(js, fjs);
}
window.weplantLayer = window.weplantLayer || [];
weplantLayer['uid'] = '#USERID#';
weplantLayer['refid'] = '#REFID#';
});
</script>
0
2. Display WePlant Badge
Add these code snippets to the header or footer templates of your website to display on all pages. Or just add to the pages you want the badge to display on.
Bottom Left (default)
<ins class='weplant-mh'> </ins>
Bottom Right
<ins class='weplant-mh' data-position='right'> </ins>
Bottom Center
<ins class='weplant-mh' data-position='center'> </ins>
Inline
<ins class='weplant-mi'> </ins>
Thank You Badge
<ins class='weplant-mh-ty'> </ins>
Thank You Badge Specific Page
<ins class='weplant-mh-ty' data-path='/example/page/only'> </ins>
Size Parameter
<ins class='weplant-mh' data-size='75'> </ins>
3. Custom Modal Content
Add any text you like in the parameter data-text. The standard modal content will not be displayed.
<ins class='weplant-mh-custom' data-text="Add any custom message and CTA you like..."> </ins>
4. Custom Tagline
Communicate why you are planting!
Oops! You need to be logged in to use this form.