Since upgrading from 1.8.3 to 1.8.4 I have a site that shows outlinks in the widget as “http:”
When I review the link they clicked on INSIDE piwik it shows that it starts with http://http://domainblahblah…
When I go to the site I am tracking the link is correct and takes the customer where he wants to go but Piwik is misreporting it in visitor report actions.
Some sites reported correctly and some didn’t have outbound clicks so I couldn’t compare. But definitely some are right and some are wrong.
I have attached screenshots of the various locations I referred to.
Hi Matt,
In my case I don’t have downloads so don’t know about that.
Outlinks are broken on ONE website and good on another. That’ll make it easy to find.
:D<
I can say that action>outlinks USED to display the link as:
“r.popshops.com” and now display as “http:”
After exploding by clicking on the plus the links:
were " /r/WmVSd…blahblah" and now are “//r.popshops.com/r/M1R… blahblah”
So it used to show only the part after the popshops part and now shows the whole thing. Plus it used to have one forward slash … now two.
If I click on the link in the exploded Actions>outlinks it takes me to http.com and then throws the popshops link behind it.
Visitors>visitor logs is where I first noticed the problem. I get action link as “http://http://r.popshops.com/blahblah”. The two http in a row is a problem.
I just took a look in the mysql database using phpMyAdmin and it appears that the links are OK in the piwik_log_action table if I am looking in the right place. So at least we got that going for us.
I just had another look in piwik_log_action and saw that all old entries (entries before Piwik 1.8.4.) where set to type 2 (for external links, I suppose) and url_prefix is NULL. All old entries are showing up right in the list of external links except for the new ones. At the moment I’m unable to look into piwiks sourcecode but maybe I’ll have time for this later.
I did a small experiment on a test environment with a copy of my piwik database. I changed the value “http://example.com” to “example.com” in piwik_log_action and as a result Visitor Log was fine again. There was no double “http://” anymore.In Action > Outlinks the error with links sorted under “http:” was still there. Maybe there are two bugs and one could be in the method splitting protocol and path.
The proper behavior is that outlinks get stored with type 2 and url_prefix NULL in log_action. If you find something else in your database, it’s a bug. Please report it in this topic.
I suspect that the problem is the distiction between 0 and NULL. Maybe you PHP/MySQL configuration doesn’t handle that properly.
To debug, please edit core/Tracker/Action.php, relacing the method reconstructNormalizedUrl:
Please post this output (or send it via email to timo at piwik o r g) and tell me the URL that is not shown correctly. The URL has to be on the page of the visitor log you are viewing when copying the debug output.
When you do this, I can check whether the distinction between NULL and 0 works in your setup. If my guess is right, we can investigate further.