Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

All Websites not showing websites #7697

Closed
bert2002 opened this issue Apr 17, 2015 · 9 comments
Closed

All Websites not showing websites #7697

bert2002 opened this issue Apr 17, 2015 · 9 comments
Labels
answered For when a question was asked and we referred to forum or answered it.
Milestone

Comments

@bert2002
Copy link

Hi,

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
z/<@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:121:450
te/<@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:175:172
p/g.success/<@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:187:199
De/e/l.promise.then/J@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:216:87
De/f/<.then/<@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:217:259
Yd/this.$get</h.prototype.$eval@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:228:28
Yd/this.$get</h.prototype.$digest@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:225:109
Yd/this.$get</h.prototype.$apply@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:228:360
m@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:187:452
w@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:192:463
ye/</B.onreadystatechange@https://itbert-stats.net/index.php?module=Proxy&action=getCoreJs&cb=1767319d3d71d3617990084d683d14dc:194:24
"

Any ideas or recommendations where to look again?

Thanks
bert2002

@mattab
Copy link
Member

mattab commented Apr 20, 2015

Hi @bert2002

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

@mnapoli
Copy link
Contributor

mnapoli commented Apr 20, 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
Copy link
Author

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

# diff -w my demo
7c7
< « {{ '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>
        </span>
    </td>
    <td ng-if="website.isGroup" class="multisites-label label">
        {{ website.label }}
    </td>
    <td class="multisites-column">
        {{ website.nb_visits }}
    </td>
    <td class="multisites-column">
        {{ website.nb_pageviews }}
    </td>
    <td ng-if="displayRevenueColumn" class="multisites-column">
        {{ website.revenue }}
    </td>

    <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>
        </div>
    </td>

    <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" />
            </a>
        </div>
    </td>

@mattab
Copy link
Member

mattab commented Apr 21, 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
Copy link
Member

tsteur commented Apr 21, 2015

This looks like pagespeed to me?

@mnapoli
Copy link
Contributor

mnapoli commented Apr 21, 2015

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

@bert2002
Copy link
Author

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
Copy link
Member

mattab commented Apr 26, 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

@tsteur tsteur added the answered For when a question was asked and we referred to forum or answered it. label Apr 27, 2015
@tsteur tsteur added this to the Piwik 2.13.0 milestone Apr 27, 2015
@bert2002
Copy link
Author

@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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it.
Projects
None yet
Development

No branches or pull requests

4 participants