How we can assign the values from javascript to Nation builder Variables ? For example
I have following Script in my code :
<script>
var url = document.write(document.URL);
</script>
So In Example I want to assign URL to Liquid mark up variable .
like :
<script>
var url = document.write(document.URL);
</script>
Please Help Me !
Official response from Gavin DeSchutter
You can use the following Liquid to produce the desired result of a full URL:
{% capture fullurlofpage } http://yournationslug.nationbuilder.com{{ request.url_path }} {% endcapture }
The liquid output of {{ fullurlofpage }} will now produce the URL of the page.
Share this post
Showing 2 reactions
Sign in with