Talk to a sales representative

+1 844-822-8378
or

Write to us

Mixpanel

Friday, March 14, 2014

Integrating VWO with MixPanel allows you to push VWO campaign data into Mixpanel reports. The integration works only if you are using VWO Synchronous code.

Follow these steps to integrate Mixpanel with VWO reports:

  1. Add the following code snippet before the Mixpanel integration code on the page you want to test. Ensure that you add this code only after the VWO smart code on the page.
    <script type="text/javascript">
    var _vis_opt_queue = window._vis_opt_queue || [], _vis_counter = 0, mixpanel = window.mixpanel || [];
    _vis_opt_queue.push(function() {
        try {
            if(!_vis_counter) {
                var _vis_data = {},_vis_combination,_vis_id,_vis_l=0;
                for(;_vis_l<_vwo_exp_ids.length;_vis_l++) {
                    _vis_id = _vwo_exp_ids[_vis_l];
                    if(_vwo_exp[_vis_id].ready) {
                        _vis_combination = _vis_opt_readCookie('_vis_opt_exp_'+_vis_id+'_combi');
                        if(typeof(_vwo_exp[_vis_id].combination_chosen) != "undefined")
                            _vis_combination = _vwo_exp[_vis_id].combination_chosen;
                        if(typeof(_vwo_exp[_vis_id].comb_n[_vis_combination]) != "undefined") {
                            _vis_data['VWO-Test-ID-'+_vis_id] = _vwo_exp[_vis_id].comb_n[_vis_combination];
                            _vis_counter++;
                        }
                    }
                }
                // Use the _vis_data object created above to fetch the data, 
                // key of the object is the Test ID and the value is Variation Name
                if(_vis_counter) {
                mixpanel.push(['register_once', _vis_data]);
                mixpanel.track("VWO", _vis_data);
              }
            }
        }
        catch(err) {};
    });
    </script>

     

  2. After adding the code, check the Mixpanel properties for VWO-Test-ID-# (where # is the test ID number). You will see the name of the variation shown to the visitor.
  3. For example VWO-Test-ID-120.

Viewing your VWO campaign ID

Follow these steps to view the campaign/test ID in VWO dashboard:

  1. Select Campaigns from the menu and click on the campaign for which you want to view the ID.
  2. In the campaign details page, select the Settings tab and click Summary as displayed in the following screenshot:
  3. Then, navigate to the Other Information section of the page to view the campaign ID.
Check Your Email!
We've sent a message to
yourmail@domain.com
with an activation link in it.
Just click the link, and we'll take it from there.
Can't find the mail?
Check your spam, junk or secondary inboxes.
Still can't find it? Let us know at support@vwo.com