diff options
Diffstat (limited to 'plugins/Live/templates/getLastVisitsStart.twig')
-rw-r--r-- | plugins/Live/templates/getLastVisitsStart.twig | 35 |
1 files changed, 26 insertions, 9 deletions
diff --git a/plugins/Live/templates/getLastVisitsStart.twig b/plugins/Live/templates/getLastVisitsStart.twig index 59a4a1fb9d..064a3545ae 100644 --- a/plugins/Live/templates/getLastVisitsStart.twig +++ b/plugins/Live/templates/getLastVisitsStart.twig @@ -19,23 +19,25 @@ {% endif %} <br /> - {% if visitor.countryFlag is defined %} <img src="{{ visitor.countryFlag }}" title="{{ visitor.location }}, {{ 'Provider_ColumnProvider'|translate }} {% if visitor.providerName is defined %}{{ visitor.providerName }}{% endif %}"/>{% endif %} - {% if visitor.browserIcon is defined %} <img src="{{ visitor.browserIcon }}" title="{{ visitor.browser }}{% if visitor.plugins is defined %}, {{ 'General_Plugins'|translate }}: {{ visitor.plugins }}{% endif %}"/>{% endif %} + {% if visitor.countryFlag is defined %} <img src="{{ visitor.countryFlag }}" title="{{ visitor.location|e('html_attr') }}, {{ 'Provider_ColumnProvider'|translate }} {% if visitor.providerName is defined %}{{ visitor.providerName }}{% endif %}"/>{% endif %} + {% if visitor.browserIcon is defined %} <img src="{{ visitor.browserIcon }}" title="{{ visitor.browser|e('html_attr') }}{% if visitor.plugins is defined %}, {{ 'General_Plugins'|translate }}: {{ visitor.plugins }}{% endif %}"/>{% endif %} {% if visitor.operatingSystemIcon is defined %} <img src="{{ visitor.operatingSystemIcon }}" title="{{ visitor.operatingSystem }}{% if visitor.resolution is defined %}, {{ visitor.resolution }}{% endif %}"/>{% endif %} {% if visitor.visitConverted %} - <span title="{{ 'General_VisitConvertedNGoals'|translate(visitor.goalConversions) }}" class='visitorRank'> + <span title="{{ 'General_VisitConvertedNGoals'|translate(visitor.goalConversions) }}" + class='visitorRank'> <img src="{{ visitor.visitConvertedIcon }}" /> <span class='hash'>#</span> {{ visitor.goalConversions }} {% if visitor.visitEcommerceStatusIcon %} - <img src="{{ visitor.visitEcommerceStatusIcon }}" title="{{ visitor.visitEcommerceStatus }}"/> + <img src="{{ visitor.visitEcommerceStatusIcon }}" title="{{ visitor.visitEcommerceStatus|e('html_attr') }}"/> {% endif %} </span> {% endif %} {% if visitor.visitorTypeIcon %} - <img src="{{ visitor.visitorTypeIcon }}" title="{{ 'General_ReturningVisitor'|translate }}"/> + <img src="{{ visitor.visitorTypeIcon }}" + title="{{ 'General_ReturningVisitor'|translate }}"/> {% endif %} {% if visitor.visitIp %} <span title="{% if visitor.visitorId is not empty %}{{ 'General_VisitorID'|translate }}: {{ visitor.visitorId }}{% endif %}"> @@ -46,33 +48,45 @@ {% if visitor.referrerType is defined and visitor.referrerType != 'direct' %} {{ 'General_FromReferrer'|translate }} {% if visitor.referrerUrl is not empty %} - <a href="{{ visitor.referrerUrl }}" rel="noreferrer" target="_blank"> + <a rel="noreferrer" target="_blank" + href="{{ visitor.referrerUrl|e('html_attr') }}"> {% endif %} + {% if visitor.searchEngineIcon is defined %} <img src="{{ visitor.searchEngineIcon }}" /> {% endif %} + {{ visitor.referrerName }} + {% if visitor.referrerUrl is not empty %} </a> {% endif %} + {% if visitor.referrerKeyword is not empty %} - "{{ visitor.referrerKeyword }}"{% endif %} + {% set keyword %}{{ visitor.referrerKeyword }}{% endset %} {% set searchName %}{{ visitor.referrerName }}{% endset %} {% set position %}#{{ visitor.referrerKeywordPosition}}{% endset %} + {% if visitor.referrerKeywordPosition is not empty %} - <span title='{{ 'Live_KeywordRankedOnSearchResultForThisVisitor'|translate(keyword,position,searchName) }}' class='visitorRank'> + <span title='{{ 'Live_KeywordRankedOnSearchResultForThisVisitor'|translate(keyword,position,searchName) }}' + class='visitorRank'> <span class='hash'>#</span> {{ visitor.referrerKeywordPosition }} </span> {% endif %} + {% elseif visitor.referrerType is defined %} {{ 'Referrers_DirectEntry'|translate }} {% endif %} </span></div> - <div id="{{ visitor.idVisit }}_actions" class="settings"> - <span class="pagesTitle" title="{{ visitor.actionDetails|length }} {{ 'General_Actions'|translate }}">{{ 'General_Actions'|translate }}:</span> + <div id="{{ visitor.idVisit|e('html_attr') }}_actions" class="settings"> + <span class="pagesTitle" + title="{{ visitor.actionDetails|length }} {{ 'General_Actions'|translate }}" + >{{ 'General_Actions'|translate }}:</span> {% set col = 0 %} {% for action in visitor.actionDetails %} {% if loop.index <= maxPagesDisplayedByVisitor %} + {% if action.type == 'ecommerceOrder' or action.type == 'ecommerceAbandonedCart' %} {% set title %} {%- if action.type == 'ecommerceOrder' %} @@ -104,7 +118,9 @@ {{ 'General_ColumnRevenue'|translate }}: {{ action.revenue|money(idSite)|raw }} {% endif %} </span> + {% else %} + {% set col = col + 1 %} {% if col >= 9 %} {% set col = 0 %} @@ -136,6 +152,7 @@ {% endif %} {% endif %} {% endfor %} + {% if visitor.actionDetails|length > maxPagesDisplayedByVisitor %} <em>({{ 'Live_MorePagesNotDisplayed'|translate }})</em> {% endif %} |