@bert2002 opened this issue on April 17th 2015


on one if my piwik installations the "All Websites" is not showing the configured websites. The installation itself is collecting and showing the data for each domain without any problem.

Version: 2.12.1 Webserver: Apache 2.2.22-13+deb7u4 + PHP 5.4.36-0+deb7u3 as FCGI (opcache not enabled)

No errors is logged (Apache or PHP) and all caches are disabled. I did reinstall Piwik as well and cleared the tmp folder.

The only problem that I can see is in the developer console on the "All Websites" page:

"Error: [$compile:tplrt] http://errors.angularjs.org/1.2.28/$compile/tplrt?p0=piwikMultisitesSite&p1=plugins%2FMultiSites%2Fangularjs%2Fsite%2Fsite.directive.html%3Fcb%3D1767319d3d71d3617990084d683d14dc

Any ideas or recommendations where to look again?

Thanks bert2002

@mattab commented on April 20th 2015

Hi @bert2002

can you check this FAQ: http://piwik.org/faq/troubleshooting/faq_18485/ - maybe it helps?

@mnapoli commented on April 20th 2015

I'm not sure if it helps but the error from the AngularJS URL is:

Template for directive 'piwikMultisitesSite' must have exactly one root element.

@bert2002 commented on April 20th 2015

@mattab thanks for pointing this out. The test page is almost identical with the page from the demo site:

# diff -w my demo
< « {{ 'General_Previous'|translate }} {{ 'MultiSites_Pagination'|translate:model.getCurrentPagingOffsetStart():model.getCurrentPagingOffsetEnd():model.getNumberOfFilteredSites() }} {{ 'General_Next'|translate }} »
> « {{ 'General_Previous'|translate }} {{ 'General_Pagination'|translate:model.getCurrentPagingOffsetStart():model.getCurrentPagingOffsetEnd():model.getNumberOfFilteredSites() }} {{ 'General_Next'|translate }} »

The template looks like this:

# cat plugins/MultiSites/angularjs/site/site.directive.js
 * Piwik - free/libre analytics platform
 * @link http://piwik.org
 * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later

 * Renders a single website row, for instance to be used within the MultiSites Dashboard.
 * Usage:
 * <div piwik-multisites-site>
 *     website="{label: 'Name', main_url: 'http://...', idsite: '...'}"
 *     evolution-metric="visits_evolution"
 *     show-sparklines="true"
 *     date-sparkline="2014-01-01,2014-02-02"
 *     display-revenue-column="true"
 *     </div>
(function () {
    angular.module('piwikApp').directive('piwikMultisitesSite', piwikMultisitesSite);

    piwikMultisitesSite.$inject = ['piwik'];

    function piwikMultisitesSite(piwik){

        return {
            restrict: 'AC',
            replace: true,
            scope: {
                website: '=',
                evolutionMetric: '=',
                showSparklines: '=',
                dateSparkline: '=',
                displayRevenueColumn: '=',
                metric: '='
            templateUrl: 'plugins/MultiSites/angularjs/site/site.directive.html?cb=' + piwik.cacheBuster,
            controller: 'MultiSitesSiteController'
# cat plugins/MultiSites/angularjs/site/site.directive.html
<tr ng-class="{'groupedWebsite': website.group, 'website': !website.group, 'group': website.isGroup}">
    <td ng-if="!website.isGroup" class="multisites-label label">
        <a title="View reports" ng-href="index.php?module=CoreHome&action=index&date={{ date }}&period={{ period }}&idSite={{ website.idsite }}">{{ website.label }}</a>

        <span style="width: 10px; margin-left:3px;">
            <a rel="noreferrer"  target="_blank" title="{{ 'General_GoTo'|translate:website.main_url }}" ng-href="{{ website.main_url }}">
            <img src="plugins/Morpheus/images/link.gif"/></a>
    <td ng-if="website.isGroup" class="multisites-label label">
        {{ website.label }}
    <td class="multisites-column">
        {{ website.nb_visits }}
    <td class="multisites-column">
        {{ website.nb_pageviews }}
    <td ng-if="displayRevenueColumn" class="multisites-column">
        {{ website.revenue }}

    <td ng-if="period != 'range'" style="width:170px;">
        <div class="visits" ng-if="!website.isGroup">
            <span ng-show="website[evolutionMetric] > 0"><img src="plugins/MultiSites/images/arrow_up.png" alt="" /> <span style="color: green;">{{ website[evolutionMetric] }}%&nbsp;</span></span>
            <span ng-show="website[evolutionMetric] == 0"><img src="plugins/MultiSites/images/stop.png" alt="" /> <span>{{ website[evolutionMetric] }}%</span></span>
            <span ng-show="website[evolutionMetric] < 0"><img src="plugins/MultiSites/images/arrow_down.png" alt="" /> <span style="color: red;">{{ website[evolutionMetric] }}%&nbsp;</span></span>

    <td ng-if="showSparklines" style="width:180px;">
        <div ng-if="!website.isGroup" class="sparkline" style="width: 100px; margin: auto;">
            <a rel="noreferrer"  target="_blank" ng-href="index.php?module=CoreHome&action=index&date={{ date }}&period={{ period }}&idSite={{ website.idsite }}"
               title="{{ 'General_GoTo'|translate:('Dashboard_DashboardOf'|translate:website.label) }}">
                <img alt="" ng-src="{{ sparklineImage(website) }}" width="100" height="25" />
@mattab commented on April 21st 2015

Do you use any third party plugin?

Maybe you can try upgrade to latest Piwik beta: http://piwik.org/faq/how-to-update/faq_159/ ?

@tsteur commented on April 21st 2015

This looks like pagespeed to me?

@mnapoli commented on April 21st 2015

Pagespeed should be detected by the system check though (but maybe the detection is broken).

@bert2002 commented on April 21st 2015

Hi @mattab no third party plugins used, but I digged into pagespeed again and mods-enabled/pagespeed.conf was not a symlink of mods-available/pagespeed.conf where I added the Disallow directive facepalm. After adding the option to the used configuration file, the "All Websites dashboard" is now working again... I feel so silly... @tsteur you are right!

@mattab commented on April 26th 2015

btw @bert2002 when pagespeed wasn't working, could you tell us if the System check is showing a warning? because we added a system check to warn when pagespeed is used, to prevent this particular issue... so it would be nice to know it still works as expected

@bert2002 commented on April 29th 2015

@mattab I tried to get back to status "not working", but I couldn't. Disabled pagespeed, removed tmp files, but "All Websites" is still working and the System Check is showing that Pagespeed is still disabled.

This issue was closed on April 21st 2015
Powered by GitHub Issue Mirror