The 'postPageView' command has the following interface:
'postPageView', breadcrumb [, hostingUrl][, optionalVariables]
Examples of use:
// Post a pageview, with breadcrumb 'Frontpage/Product/Dolls'
$netminers.push(
['postPageView', 'Frontpage/Product/Dolls']
);
// Post a pageview, with breadcrumb 'Frontpage/Product/Dolls' and link an optional property 'knownuser' via JSON to the pageview.
$netminers.push(
['postPageView', 'Frontpage/Product/Dolls', { 'knownuser': 'true' }]
);
// Post a pageview, with breadcrumb 'Frontpage/Product/Dolls' and add a custom url 'http://www.toysinc.com/newproductsection' instead of the current url location.
$netminers.push(
['postPageView', 'Frontpage/Product/Dolls', 'http://www.toysinc.com/newproductsection/dolls']
);
// Usage of supplying a function to return the breadcrumb. The function creates and returns the breadcrumb 'Frontpage/Product/Dolls'.
$netminers.push(
['postPageView', function(t) {
var bc = [];
bc.push('Frontpage');
bc.push('Product');
bc.push('Dolls');
return bc.join('/');
}
]
);
// Post a pageview, with breadcrumb 'Frontpage/Product/Dolls'
// Add a custom url 'http://www.toysinc.com/newproductsection' instead of the current url location
// Link an optional property 'knownuser' via JSON to the pageview.
$netminers.push(
['postPageView', 'Frontpage/Product/Dolls', 'http://www.toysinc.com', { 'knownuser': 'true' }]
);