codifex
Forum Replies Created
-
Forum: Plugins
In reply to: [Yoast SEO] We've updated our SEO score algorithm.Same problem here on a multisite install after updating to 3.0.3. No caching plugins in use at all.
Any solution is really appreciated.
Thank you for your effort in solving this problem. It is highly appreciated!
Does using the auth token of a user with view privileges only keep logging enabled?
I now even got multiple duplicates for a certain site.
I am wondering if Piwik creates the duplicates on its own or if they are created by WP-Piwik.
I am now using 1.0.2 and the problem occured again.
https://example.org/ru has been added twice in Piwik, but shows only once (correclty) in WP-Piwik.
I followed the procedure described above and ran the test script for the specific blog. Here is what it returned for the affected site:
Test 3/3: SitesManager.getSitesIdFromSiteUrl array(2) { [0]=> array(1) { ["idsite"]=> string(1) "2" } [1]=> array(1) { ["idsite"]=> string(1) "7" } }
Site ID 2 is the correct site ID whereas site ID 7 is the erroneously duplicated version.
Any ideas are welcome!
BTW, I switched to the PHP API and then back to HTTP API because the PHP did not work because of basedir restriction errors. After doing that the site ID emitted by WP-Piwik in both the backend and on the site was “n/a”. I fixed this by resetting the WP-Piwik settings.
It’s a HTTP API connection.
PHP API does not work because of basedir restrictions on the server.
It seems that Piwik’s
SitesManager.addSite
can be called multiple times with the same address and Piwik creates entries in its sites table without an error. AFAIS the functionaddPiwikSite
in WP-Piwik callsSitesManager.addSite
. I am not familiar with the WP-Piwik source code, but maybe this function is invoked for some reason for sites that already exist in Piwik. Any input is appreciated.Today just one of about 22 sites has been added automatically about 10 times… really weird.
The WP-Piwik backend works as expected, no connection problems.
Are you using a HTTP or a PHP connection?
How to determine that?
I updated from 1.0 to 1.0.1. In the meantime a duplicate has been added again.
Interestingly the duplicate with the new ID does NOT show up in WP-Piwik’s site browser.
Here is an excerpt from the test script result:
[12]=>
array(16) {
["idsite"]=>
string(2) "13"
["name"]=>
string(30) "Example Site"
["main_url"]=>
string(20) "https://example.org"
["ts_created"]=>
string(19) "2014-10-07 21:34:43"
["ecommerce"]=>
string(1) "0"
["sitesearch"]=>
string(1) "1"
["sitesearch_keyword_parameters"]=>
string(0) ""
["sitesearch_category_parameters"]=>
string(0) ""
["timezone"]=>
string(13) "Europe/Vienna"
["currency"]=>
string(3) "EUR"
["excluded_ips"]=>
string(0) ""
["excluded_parameters"]=>
string(0) ""
["excluded_user_agents"]=>
string(0) ""
["group"]=>
string(0) ""
["type"]=>
string(7) "website"
["keep_url_fragment"]=>
string(1) "0"
}
...
[22]=>
array(16) {
["idsite"]=>
string(2) "30"
["name"]=>
string(30) "Example Site"
["main_url"]=>
string(20) "https://example.org"
["ts_created"]=>
string(19) "2015-05-31 20:03:01"
["ecommerce"]=>
string(1) "0"
["sitesearch"]=>
string(1) "1"
["sitesearch_keyword_parameters"]=>
string(0) ""
["sitesearch_category_parameters"]=>
string(0) ""
["timezone"]=>
string(13) "Europe/Vienna"
["currency"]=>
string(3) "EUR"
["excluded_ips"]=>
string(0) ""
["excluded_parameters"]=>
string(0) ""
["excluded_user_agents"]=>
string(0) ""
["group"]=>
string(0) ""
["type"]=>
string(7) "website"
["keep_url_fragment"]=>
string(1) "0"
}In Piwik, both sites have the same config (exactly the same URL, protocol, slashes, etc.).
I will provide the information if the problem occurs again. Thank you for your quick reply.
I agree, it’s just one additional click I have to do, so I’d prefer to see a notice only in case something in the plugin’s settings has actually changed.
Back to my problem:
I updated from 0.9.9.18 to 0.10.0.7. The problem still occured (it’s a multisite network with about 20 sites).
However, it seems that uninstalling/reinstalling 0.10.0.7 fixes the problem of the mixed up Piwik site IDs.
Thank you for your quick reply.
German: example.org has site ID 1
Russian: example.org/ru has site ID 2
English: example.org/en has site ID 3As far as I see site ID 2 was emitted for the root site example.org instead of the correct site ID 1. The visits of the German site show up in the statistics for the Russian site. The statistics for the English site seem to be correct.
In the backend’s plugin settings page
_paq.push(['setSiteId', 2]);
was shown in the tracking code sample. After uninstalling/reinstalling the plugin the line reads_paq.push(['setSiteId', 1]);
.I updated from 0.9.9.18 to 0.10.0.7 on the test system. I also updated the whole blog network, although I am not sure if this is even required when updating a plugin only. Using WordPress 4.2.2 and Piwik 2.13.0.
Logged out and logged back into the backend again, logged out/in from multiple clients, disabled/enabled the plugin and even uninstalled/reinstalled it. In any case the result is the same.
1. Network Dashboard -> Settings -> WP-Piwik -> Support -> Site browser.
This still leads to the error message “Du hast nicht die erforderlichen Rechte, um auf diese Seite zuzugreifen.” The URL of the error page is https://example.org/wp-admin/options-general.php?page=wp-piwik/classes/WP_Piwik.php&sitebrowser=1, “example.org” is just a placeholder I used here. The user is the blog network’s super user and admin of each blog.
2. Network Dashboard -> Dashboard -> WP-Piwik
Works as expected and the IDs shown for the sites here are correct. The correct site IDs are also shown when running the test script.
After the update wrong IDs were emitted by the tracking script (although the test script and Dashboard -> WP-Piwik reported the correct site IDs), thus scrambling Piwik statistics. However, it seems that after reinstalling the plugin this issue is fixed (I am still testing and I’ll report my findings later).
Thank you for your commitment.
The problem is caused by inclusion of
jquery-ui-tooltip
. I checked this by disabling all tooltips using jQuery ($('*').tooltip( { disabled: true } );)
.This fixed the problem of having to click twice for the click event to be fired on Safari Mobile.
However, it also disables the description shown below each image in the shutter.
I am not familiar with the NextCellent code, but it seems that the jQuery UI tooltips are added to all (!) HTML elements on the page in “ngg.js” on lines 27 to 34:
//Activate tooltip. Allow HTML content. //See https://jqueryui.com/tooltip/ for examples. //See https://stackoverflow.com/questions/15734105/jquery-ui-tooltip-does-not-support-html-content jQuery(document).tooltip({ content: function () { return jQuery.parseHTML(this.getAttribute("title")); } });
I believe that a plugin MUST NOT change the behavior of other elements on the page.
I am not sure at all why jQuery UI tooltip is required here at all to display the image title.
Proposed fix:
I was able to fix the problem by changing the selector in “ngg.js” on lines 27 to 34 as shown below. The tooltip will only be added to the shutter:
//Activate tooltip. Allow HTML content. //See https://jqueryui.com/tooltip/ for examples. //See https://stackoverflow.com/questions/15734105/jquery-ui-tooltip-does-not-support-html-content jQuery('shTopImg').tooltip({ content: function () { return jQuery.parseHTML(this.getAttribute("title")); } });