If your website is a Single Page App (SPA), a visitor can browse your pages without a single page reloading.

By default Exit Bee does not track such kind on browsing, but you can update your site settings in order to track the pages properly.


On your site's settings page, there is a "SINGLE PAGE APPLICATION TRACKING" section.

Let's take a closer look at each one of the options :





Track page views automatically excluding fragments


This is the default tracking mode. With this setting, the tracking will not consider a fragment change as a new page track.

Example browsing scenario:

http://test.com -> http://test.com/#shop  -> http://test.com/#product -> http://test.com/

The tracker will track a single page browsing of http://test.com page.


Track page views automatically including fragments


With this mode, a fragment change will fire a new page track.

Example browsing scenario:

http://test.com -> http://test.com/#shop  -> http://test.com/#product -> http://test.com/

The tracker will track 4 pages browsing, each page will contain different fragment, as shown above.


Track page views manually


By selecting this mode,  you are responsible for the page tracking. The tracker will track nothing unless you add some script on your website telling it what you want to track.

In order to manually track the pages browsing you need to implement 2 steps :


1. Append the following line to the Exit Bee's default tracking code.

window.eb=window.eb||function(){(eb.q=eb.q||[]).push(arguments)};


2. When you want to track a page view call: 

eb('trackAction', 'served', {{your_full_page_url}});  


where {{your_full_page_url}} is a full page url with protocol, fragments and query string. For example :


eb('trackAction', 'served' , 'http://test.com/#product?case=2');


Instead of passing the tracked page in the function above, you can preset it using :

eb('setPage', {{your_full_page_url}});

eb('trackAction', 'served');


If you preset your tracked page using setPage(), all the upcoming tracks will use this as a page, unless you pass a new page in the 'trackAction'.