I was told a while ago by support that when using the munchkin tracking on a domain which top level domain had only 2 letters, we had to set the domainlevel munchkin init parameter to 2.
Reading the doc, it seems that this parameter has a totally different effect :
Sets the number of pieces from the page’s domain to use when setting the domain parameter of the cookie: domainLevel: 2 will set the domain parameter to “.example.com,” while domainLevel: 3 will set the cookie to “.www.example.com.” |
Based on this doc, it seems that the use of it would be to handle situations such as mydomain.co.uk (common UK URL) or mydomain.com.br (Common Brazilian one) (in which cases it should be set to 3)
Question 1: Who is right, the support or the doc ?
Question 2: I also gather from the fact that the parameter is not usually needed when on a mydomain.com domain, the default value is 2. Is this correct ?
Question 3: do I have to change it on a Marketo LP that is hosted in a mydomain.com.br ?
-Greg
Solved! Go to Solution.
Question 1: Who is right, the support or the doc ?
The doc is more correct, but the overall picture is more complex (and has major bugs).
When computed dynamically, the domainLevel does take into account the number of letters in the TLD. The effort is to intuit the registered domain (the highest level at which the browser will let you set cookies) but it clearly does not always work.
When you set it statically, the domainLevel doesn't have any direct relationship to the number of letters in any component. You should set it to the true level at which you want to set the cookie, even if the domain is my www.example.somereallylongtld.
Question 2: [O]n a mydomain.com domain, the default value is 2. Is this correct ?
When specifically on an example.com domain, yes.
Question 3: [D]o I have to change it on a Marketo LP that is hosted in a mydomain.com.br ?
No, because it will dynamically set to 3 but I would set it manually anyway.
Question 1: Who is right, the support or the doc ?
The doc is more correct, but the overall picture is more complex (and has major bugs).
When computed dynamically, the domainLevel does take into account the number of letters in the TLD. The effort is to intuit the registered domain (the highest level at which the browser will let you set cookies) but it clearly does not always work.
When you set it statically, the domainLevel doesn't have any direct relationship to the number of letters in any component. You should set it to the true level at which you want to set the cookie, even if the domain is my www.example.somereallylongtld.
Question 2: [O]n a mydomain.com domain, the default value is 2. Is this correct ?
When specifically on an example.com domain, yes.
Question 3: [D]o I have to change it on a Marketo LP that is hosted in a mydomain.com.br ?
No, because it will dynamically set to 3 but I would set it manually anyway.
Hi Sanford,
Thx, that is much clearer.
So, for anyone else involved in an International roll-out and reading this post (Please Sanford correct me if I am wrong) :
-Greg
EDIT : corrections made following Sanford's comments below.
Ah, not quite! Notice I bolded ".com" in my response because that's what you were spec'ly asking about. The same does not apply to other TLDs. Even when the registered domain is, factually, the second-level domain, if the TLD has 2 letters Munchkin makes erroneous assumptions about the registered domain.
So actually .fr is treated like .com.br which obviously is incorrect. Munchkin default works for the latter, as I said, but not the former.
I'll write more later as I had to step out for a bit and mobile is not the way to post...
Hi again Sanford,
So it's really bugged!
-Greg
Yes, it is quite buggy. Luckily -- due largely to coincidence -- most sites will not encounter the bugs. Yet because they've dodged the bugs due to luck as opposed to deliberate configuration, a seemingly minor change to site architecture can wreak havoc on tracking. And there are some sites that are dealing with the bugs right now: they're missing Munchkin activities and they don't why.
First, some info about the modern web, domains, and cookies:
The principal problem is that Munchkin believes the length of the TLD is meaningful for predicting the registered domain when, as you can see in [2] above, this is plainly untrue. For example, I can register figureone.mx. If I go to http://www.figureone.mx Munchkin assumes the registered domain is the 3LD www.figureone.mx and sets a cookie accordingly. If I go to http://info.figureone.mx Munchkin assumes the registered domain is the 3LD info.figureone.mx and sets a new cookie accordingly. I'm sure you can see that can create a very difficult to troubleshoot situation... a tracking disaster.
The reason I mentioned that example.com works without further config is that Munchkin's intuition works for .com. It also works for example.com.br because .br requires registrants to have a 3LD (3LD.{{mandatory public suffix SLD}}.TLD).
Adding additional confusion is that if your main site uses the new-style http://{{zone apex}} as in [1] with a TLD like .io, you can get different results depending on whether someone hits your main site first or your Marketo-hosted LPs!
Bottom line: must set your domainLevel if you are using any 2-letter TLD, should set your domainLevel always.
That's a comprehensive answer!
Would indeed be worth a blog post.
Thanks very much.
-Greg
Maybe you could make a tech space on your blog and post a translation... I'm just a lot better at blog-length answers than actual blogging.
The subsidiary question is: how do we modify the default munchkin on a Marketo hosted LP using a guided template ?
Answer, if I'm not mistaken, is:
-Greg
Hi again Sanford,
And there are some sites that are dealing with the bugs right now: they're missing Munchkin activities and they don't why.
I think some sites are having tracking bugs and have not even noticed
-Greg