Hello, i am currently Yahoo tracking code and have problems with the templating engine.
The code i am implementing looks like:
<script type="text/javascript">
/*globals YWA*/
var YWATracker = YWA.getTracker('xxxx');
<% if Menu(3) %>
YWATracker.setDocumentGroup('/$Level(1).URLSegment/$Level(2).URLSegment');
YWATracker.setCF(8, '$Level(1).MenuTitle');
YWATracker.setCF(9, '$Level(2).MenuTitle');
YWATracker.setCF(10, '$Level(3).MenuTitle');
<% else_if Menu(2) %>
YWATracker.setDocumentGroup('$Level(1).URLSegment');
YWATracker.setCF(8, '$Level(1).MenuTitle');
YWATracker.setCF(9, '$Level(2).MenuTitle');
<% else %>
YWATracker.setDocumentGroup('$Level(1).URLSegment');
YWATracker.setCF(8, '$Level(1).MenuTitle');
<% end_if %>
YWATracker.setDocumentName('$ElementName');
YWATracker.setDomains('$YahooDomains');
YWATracker.setCF(7, '$Locale.Nice');
YWATracker.setCF(11, 'XXXX');
YWATracker.submit();
</script>
The HTML output is:
<script type="text/javascript">
/*globals YWA*/
var YWATracker = YWA.getTracker('xxxx');
YWATracker.setDocumentGroup('/about-us/brand-model');
YWATracker.setCF(8, 'About Us');
YWATracker.setCF(9, 'Brand Model');
YWATracker.setCF(10, '');
<% else_if Menu(2) %>
YWATracker.setDocumentGroup('about-us');
YWATracker.setCF(8, 'About Us');
YWATracker.setCF(9, 'Brand Model');
YWATracker.setDocumentName('about-us-brand-model');
YWATracker.setDomains('XXXX');
YWATracker.setCF(7, 'English');
YWATracker.setCF(11, 'XXXX');
YWATracker.submit();
</script>
I also tried with double-quotes inside the <script> tags, but it did not change anything (incl. flush). Did i miss something? Any hints how to solve this issue?