No Tracking after 301 redirect to "www"

Dear Piwik Team,

i have a Problem for which i was unfortunatelly not able to find a solution in your forum.
On our website, we were using piwik for about a year without problems.
But then, we added a 301 redirect in the htaccess which redirects all “example.de” to “www.example.de”.
From that moment, Piwik stopped tracking.

It yould really help me a lot if you had an idea to solve the problem :slight_smile:

For your Info: The Piwik-Installation Folder is in our root ( “/” ).

The htaccess contains the following:
RewriteEngine On
RewriteCond %{HTTP_HOST} !^www.
RewriteRule ^(.*)$ http://www.%{HTTP_HOST}/$1 [R=301,L]

Thanks a lot in advance!

Could it be that the Javascript tracking code (that you added inside your website) still uses the old “example.de/piwik…” URL?

Thanks for the hint! That was ist :slight_smile:
I have adjusted the following in the tracking-code:
“setCookieDomain”
"setDomains"
var u=((“https:” == document.location.protocol)

Now, it’s tracking again :slight_smile:
Sorry, first time that i’m using Piwik…

Kind regards,
Pete