I want to know about the trackPageView
function,
There are 2 different results on the trackPageView
function. The difference occurs when using a variable in the callback.
The variable is empty,
first :
_paq.push(['trackPageView','Variable']);
The Variable 's avg_time_on_page result
is always 1 sec.
second :
_paq.push(['trackPageView']);
It's default, without arguments, the avg_time_on_page result is correct.
<script type="text/javascript">
var _paq = _paq || [];
var pid = '<?php echo $postid;?>';
_paq.push(['trackPageView',pid]);
_paq.push(['trackPageView']);
_paq.push(['trackEvent', 'arcpost', 'wsite', pid]);
_paq.push(['enableLinkTracking']);
(function() {
var u="<?php echo JSPIWIK_URL;?>";
_paq.push(['setTrackerUrl', u+'piwik.php']);
_paq.push(['setSiteId', <?php echo JSPIWIK_SITEID;?>]);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
})();
</script>
default:
PAGE NAME :The boys, please... AVG. TIME ON PAGE: 55s
var: gubof1
PAGE NAME :gubof1 AVG. TIME ON PAGE: 1s
How is this possible?