Omniture PageName tracking both custom PageName & PageURL in Omniture suite I want only custom PageName to be tracked

StackOverflow https://stackoverflow.com//questions/24063210

  •  02-01-2020
  •  | 
  •  

Question

I'm facing an issue in Omniture on page load i want to track custom PageName so i add this script at bottom of the page

<script language="JavaScript" type="text/javascript"><!--
/* You may give each page an identifying name, server, and channel on
the next lines. */
pageName = "abc.com:home"
s.server=""
s.channel=""
s.pageType=""
s.prop1=""
s.prop2=""
s.prop3=""
s.prop4=""
s.prop5=""
/************* DO NOT ALTER ANYTHING BELOW THIS LINE ! **************/
var s_code=s.t({pageName:pageName});if(s_code)document.write(s_code)//--></script>
<!-- End SiteCatalyst code version: H.20.3. -->  

when ever page loads i checked through debugger tool PageName is assign with "abc.com:home" but when i checked in Omniture Suite report & analytics --> site content --> Pages - both custom PageName & page URL is getting tracked i want only custom PageName to be tracked in the suite please can one share there views or ideas how to get rid off with page URL.

Was it helpful?

Solution

From your comment:

Hi Crayon thank you for your response 1.yup my customer requested for custom page name for all the pages through out the site. We are using a CMS tool for the site above code is hard coded in master template 2. yes I'm calling another s.t() on page load to capture other events,prop,evar.. 3. If i pass s.PageName="abc.com:home" whenever I'm calling another s.t() PageName is getting captured in another s.t() to reduce duplication of PageName I'm passing it as parameter. 4. I also cross checked with other debugging tools only in one beacon I'm passing pagename

Okay so the reason you are seeing both pageName value and URL in your pages reports is because you have two s.t() calls, and only 1 of them has a value for s.pageName. You said you are passing pageName value to avoid getting the page counted twice. Well it's already happening, because you are using two s.t() calls. Since you do not specify a pageName in the 2nd one, the URL is the default.

The ideal solution is to restructure your code to only have one s.t() call. You said you are working with a CMS. So ideally you should have your s_code.js script tag in a global header include. then you should have one s.t() call in a global footer include. You could also put global vars in the footer section (or within s_code.js > s_doPlugins function). Then in between those two is where you would put any page specific custom code. It seems to me that you are already kinda doing this.. but you just need to remove the first s.t() call.

If for whatever reason you cannot achieve the ideal solution, you should instead make use of s.tl() for the 2nd request. To use s.tl(), you would do something like this:

s.prop1='foo';
s.eVar1='bar';
s.events='event1';
s.linkTrackVars='prop1,eVar1,events';
s.linkTrackEvents='event1';
s.tl(true,'o','description');

Basically, any props, eVars and events you want to track in s.tl call will need to be declared in linkTrackVars and linkTrackEvents.

NOTE: You should really strive for the ideal solution. It's not just the pages report that can get inflated. Any other vars you set will get inflated too. Also, Adobe's payment model is to charge for every single request made to their server, so your customer will likely not like the fact that you are doubling their bill by doing this.

The s.tl method is by no means ideal, but it is better than what you are doing now. as it will reduce report inflation, and s.tl requests cost less than s.t requests.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top