All I'm seeing is the default page!
This is a follow up to Show me some ID in which I wrote about how to get the full path to show up in your latest page views report when your site content is dynamically generated.
What I didn't cover was a quirk relating to a site's index page. In FlySoup this defaults to, well... 'default', regardless of any query string.
So what happens if your dynamic content is based off a page called index.php. All you see is 'default page'. Not particularly useful.
Here's the work around.
As before, you will need to make a small adjustment to the tracking script.
In the tracking script, change
wa_pageName=location.pathname; // you can customize the page name here
to read
wa_pageName=' '+location.pathname+location.search;
In the changed line, you can leave just a space between the two single quotes, or you can make it 'your site name' or 'Page ' or something similar. Whatever you put will precede the page name and query string.
Labels: dynamic urls, FlySoup

0 Comments:
Post a Comment
Links to this post:
Create a Link
<< FlyPosting Home