Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This behavior can be switched off by setting: spring.ns = true

...

defining the springconfig variable before loading the JS library: 
var springconfig = {"survey":false};

Synchronous Tagging (Supported since version 1.6.3 of the sensor library):

Code Block
languagejava
linenumberstrue
<html>
<head>
</head>
<body>
	 <script type='text/javascript'>
	 	var springconfig = {"survey":false};
	 </script>
     <script src="spring.js">
	 </script>
     <script type='text/javascript'>
		  var sp_e0 = {
            "s":"testsite",
            "cp":"Path/to/your/page", //Please go to Chapter ContentPath(cp)
            "url": document.location.href
           };
        spring.c(sp_e0);
     </script>
</body>
</html> 

The synchronous mode will still support the spring.ns setting (which was introduced with version 1.6.0 of the sensor library, so full downward compatibility is given):

="Javascript"
Code Block
language
java
linenumberstrue
<html>
<head>
</head>
<body>
     <script src="spring.js">
	 </script>
     <script type='text/javascript'>
          spring.ns = true;
		  var sp_e0 = {
            "s":"testsite",
            "cp":"Path/to/your/page", //Please go to Chapter ContentPath(cp)
            "url": document.location.href
           };
        spring.c(sp_e0);
     </script>
</body>
</html> 

 

Asynchronous Tagging (Supported since version 1.6.3 of the sensor library):

Code Block
languagejavascript
firstline1
linenumberstrue
<html>
<head>
<script type="text/javascript">
    var springns=true;
    var springq =
     springq || [];
      springq.push({
            "s":"testsite", 
            "cp":"Path/to/your/page", //Please go to Chapter ContentPath(cp)
            "url": document.location.href
      });

 </script>
 </head>
<body>
<script type="text/javascript">

// some other script

</script>

<!-- some stuff goes here -->
 

<!-- end of page -->

<script type="text/javascript">  (function() {
	springconfig = {"survey":false};
    var scr = document.createElement('script');  
    scr.type = 'text/javascript'; scr.async = true;
    scr.src = 'spring.js';
    var s = document.getElementsByTagName('script')[0];  
    s.parentNode.insertBefore(scr, s);
    })();

</script>
</body>
</html>