Skip to content

Instantly share code, notes, and snippets.

@tomfuertes
Created July 25, 2012 18:24
Show Gist options
  • Select an option

  • Save tomfuertes/3177703 to your computer and use it in GitHub Desktop.

Select an option

Save tomfuertes/3177703 to your computer and use it in GitHub Desktop.
AnalyticsDataLayer Updates | Calendar
<!-- Starting on line line 764 of /haoi/611.1009820.1291204/calendar/year.html -->
<div id="analyticsData" data-analytics-appEnvironment="stage" data-analytics-brand="HolidayRentals"
data-analytics-viewName="&#x2f;calendar&#x2f;year" data-analytics-detailTypeSingular=""
data-analytics-userID="7977cf4c858c46f4b84edcb3fa204d56" data-analytics-propID=""
data-analytics-listingID="" data-analytics-reservationID="" data-analytics-calendarID=""
data-analytics-isNewReservation="" data-analytics-listingAction="" data-analytics-UMS-GUID=""
data-analytics-purchaseID="" data-analytics-productName="" data-analytics-productQuantity=""
data-analytics-productPrice="" data-analytics-inquiryId="" data-analytics-pageType=""
data-analytics-pageName="" data-analytics-visitorType="owner" data-analytics-testing=""
data-analytics-ppc="">&nbsp;</div>
<script type="text/javascript">
var analyticsdatalayer = {
'appenvironment': "REPLACEME", // <-- Replace this with a raw string of appenvironment
'brand': "REPLACEME", // <-- Replace this with a raw string of brand
'viewname': "REPLACEME", // <-- Replace this with a raw string of viewname
'detailtypesingular': "REPLACEME", // <-- Replace this with a raw string of detailtypesingular
'userid': "REPLACEME", // <-- Replace this with a raw string of userid
'propertyid': "REPLACEME", // <-- Replace this with a raw string of propertyid
'listingid': "REPLACEME", // <-- Replace this with a raw string of listingid
'reservationid': "REPLACEME", // <-- Replace this with a raw string of reservationid
'calendarid': "REPLACEME", // <-- Replace this with a raw string of calendarid
'isnewreservation': "REPLACEME", // <-- Replace this with a raw string of isnewreservation
'listingaction': "REPLACEME", // <-- Replace this with a raw string of listingaction
'guid': "REPLACEME", // <-- Replace this with a raw string of guid
'orderid': "REPLACEME", // <-- Replace this with a raw string of orderid
'productname': "REPLACEME", // <-- Replace this with a raw string of productname
'productquantity': "REPLACEME", // <-- Replace this with a raw string of productquantity
'productprice': "REPLACEME", // <-- Replace this with a raw string of productprice
'inquiryid': "REPLACEME", // <-- Replace this with a raw string of inquiryid
'pagetype': "REPLACEME", // <-- Replace this with a raw string of pagetype
'pagename': "REPLACEME", // <-- Replace this with a raw string of pagename
'visitortype': "REPLACEME", // <-- Replace this with a raw string of visitortype
'testing': "REPLACEME", // <-- Replace this with a raw string of testing
'ppc': "REPLACEME" // <-- Replace this with a raw string of ppc
}
// Delete function analyticsGetPageNameAndType -
// We need to set these inline and before calling the Ensighten tag
// Setting them OnPageLoad will cause our tracking to err
</script>
<script type="text/javascript">
(function () {
var s = document.getElementsByTagName('script')[0];
var e = document.createElement('script');
e.type = 'text/javascript';
e.async = true; // <-- Improves performance
e.src = "//nexus.ensighten.com/homeaway/Bootstrap.js";
s.parentNode.insertBefore(e, s);
})();
</script>
<!-- .. SNIP .. -->
<!-- Line 27185 -->
var payload = {
"pageName": "owner - view calendar", // Use this for pagename above
"channel": "dashboard - calendar", // Use this for pagetype above
"name": "calendar is up to date",
"event": "event6",
"linkTrackVars": "events,prop34,prop35,prop36,prop37,prop38,eVar24",
"linkTrackEvents": "event6",
"brandAbbr": "HolidayRentals",
"modelParams": {
"environment": "stage",
"themeName": "HolidayRentals",
"viewName": "&#x2f;calendar&#x2f;year",
"userUuid": "7977cf4c858c46f4b84edcb3fa204d56",
"propertyId": "",
"listingId": "",
"reservationId": "",
"calendarId": "",
"listingAction": ""
}
};
@tomfuertes
Copy link
Copy Markdown
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment