3 ms·
You could also put `if (navigator.doNotTrack === "1") { return }` at the top of your script. https://developer.mozilla.org/en-US/docs/Web/API/Navigator/doNotTr
by hellcow 9y ago
You could also put `if (navigator.doNotTrack === "1") { return }` at the top of your script.
https://developer.mozilla.org/en-US/docs/Web/API/Navigator/doNotTrack https://developer.mozilla.org/en-US/docs/Web/API/Navigator/d...
- amenod 9y agoIf you do that, you might want to add a message saying that you disabled all JS functionality on the site because of DNT, because it is not something users would expect to happen. If I set DNT and go to youtube.com, I would expect to see video anyway. The same for embedded videos on some blog. I am not saying this is a bad way (it is much better than many others), just that users should be made aware of the cause.
- bArray 9y agoThank you for this, I implemented a respectful DoNoTrack inspired by this comment: http://coffeespace.org.uk/dnt.js http://coffeespace.org.uk/dnt.js http://coffeespace.org.uk/projects/do-not-track.html http://coffeespace.org.uk/projects/do-not-track.html