Knowledge base | mouseflow

Eloqua Integration

With Mouseflow, it's easy to integrate with other tools like Eloqua. To save the Eloqua session ID into Mouseflow (for sorting/filtering based on this value), you can extract the data from the user's cookies and send it to Mouseflow.

This integration example uses the js-cookie library. Add it to your site by adding this line:

<script src="https://cdnjs.cloudflare.com/ajax/libs/js-cookie/2.1.4/js.cookie.min.js"></script>

Example:

<script type="text/javascript">

    // mouseflow tracking code
    window._mfq = window._mfq || [];
    (function() {
        var mf = document.createElement("script"); mf.type = "text/javascript"; mf.async = true;
        mf.src = "//cdn.mouseflow.com/projects/your-website-id.js";
        document.getElementsByTagName("head")[0].appendChild(mf);
    })();

    // eloqua integration code
    if (Cookies.get('ELOQUA')) {
        _mfq.push(["setVariable", "eloqua_id", Cookies.get('ELOQUA')]);
    }
</script>