Skip to content

Instantly share code, notes, and snippets.

@midu
Created April 9, 2012 15:27
Show Gist options
  • Select an option

  • Save midu/2344225 to your computer and use it in GitHub Desktop.

Select an option

Save midu/2344225 to your computer and use it in GitHub Desktop.
<script type="text/javascript">
var _cio = _cio || [];
(function() {
var a,b,c;a=function(f){return function(){_cio.push([f].
concat(Array.prototype.slice.call(arguments,0)))}};b=["identify",
"track"];for(c=0;c<b.length;c++){_cio[b[c]]=a(b[c])};
var t = document.createElement('script'),
s = document.getElementsByTagName('script')[0];
t.async = true;
t.id = 'cio-tracker';
t.setAttribute('data-site-id', 'YOUR SITE ID HERE');
t.src = 'https://app.customer.io/assets/track.js';
s.parentNode.insertBefore(t, s);
i })();
_cio.identify({
id: 'production_34', // must be unique per customer
email: '[email protected]',
created_at: 1333688268, // seconds since the epoch (January 1, 1970)
name: 'Joe',
plan: 'premium'
});
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment