3 ms·
I'm curious what you mean by when you say "track user sessions". Are you talking across multiple sites? Pages on the same domain? Or all sites that are running
by pseudonym 16y ago
I'm curious what you mean by when you say "track user sessions". Are you talking across multiple sites? Pages on the same domain? Or all sites that are running your analytics?
You explicitly, for good reason, cannot read and write cookies from another domain. What you can do, however, is host a PHP script that displays as an image on a 3rd party server (http://www.configure-all.com/howto_display_image.php http://www.configure-all.com/howto_display_image.php), and use that script to write cookies or store information on that server's domain.
- EGreg 16y agoLet's say I navigate to publisher.com If publisher.com has an iframe, img or other element with src coming from analytics.com, then (almost) all browsers will allow reading cookies from it. That is how e.g. commenting systems know who you are across domains. However, safari is the only browser that doesn't seem to allow WRITING to a domain other than the one you have navigated to, using any method. (Not even loading img tags.) I was wondering if there was a way around it. Someone said that doing a POST to an iframe used to work http://anantgarg.com/2010/02/18/cross-domain-cookies-in-safari/ http://anantgarg.com/2010/02/18/cross-domain-cookies-in-safa... but now people are saying it doesn't anymore
- pseudonym 16y agoConsidering the number of pages that rely on that php-image style scripting for simple things (like page hits), I'd be surprised if that didn't work on Safari. Sadly I don't have a Mac on hand, so I can't test it myself.