Piwik Campaign-Tracking and Apache mode_rewrite


#1

Hi all
i’m new to Piwik-Forum. I installed piwik 1.6 on my oscommerce webshop. Everthing works fine so far, but I have a problem to track campaigns.
I use a SEO Url Extension for the webshop, so my Shop generates URL as *.html pages. In the apache .htaccess, there are the rules to rewrite the html-URL’s to the corresponding php-Script.
Now I have the Problem, that tracking seems to work as long as I use URL’s, that point to the php-script directly. If I try to track html-URL’s , tracking doesn’t work. Apparently the pk_campaign-Parameter in the URL seems to be lost after the rewrite to php in Apache. This is a bit astonishing because other url-parameter (like language and currency) are passed to the php-script.

Is this possible? Are there any ideas on how to fix this issue?

Regards
Peter


#2

Hi all
I could solve the problem.
It was not a problem with Apache mode_rewrite, but with mode_security.
In Firefox, I got an Error 403 access denied when calling the /piwik/piwik.php?.. - Tracker.
To solve the problem, user the POST Method of Piwik in the javascript api:

“piwikTracker.setRequestMethod(‘POST’);”

Now everything works fine.
Regards
peter


(Huang0808) #3

@techspiel have you meet this issue below:

If I OPEN https://www.xx.com/cn/diamonds?utm_source=baidu&utm_medium=cpc&utm_campaign=BJ_Diamond&click_id=72899071

have visitor.

THEN open other link in website that will show new keyword and new visitor

THEN I refresh the first link https://www.xx.com/cn/diamonds?utm_source=baidu&utm_medium=cpc&utm_campaign=BJ_Diamond&click_id=72899071

will have new visitor again.

Could you help me see what is the issue?