JavaScript Snippet
TO set custom parameters:
- Login to Console.
- Go to Platform Settings > Applications > Overview.
- Select the required application and go to Integration details.
- In the Snippet window, click Copy.
- Before embedding the snippet into your application, add this line of code for each custom parameter:
window._pxParamN = "<paramN_value>"
.
Example
To extract the value of my_cookie
, add a custom parameter in this format:
<script type="text/javascript">
(function(){
window._pxAppId =APP_ID;
// Custom parameters
window._pxParam1 = getCookie('my_cookie');
var p = document.getElementsByTagName('script')[0],
s = document.createElement('script');
s.async = 1;
s.src = '//client.perimeterx.net/APP_ID/main.min.js';
p.parentNode.insertBefore(s,p);
}());
</script>
Updated 12 days ago