After some simple troubleshooting, I found the problem and failed to set the cookie.
But as to why the failure occurred, I checked the problem for half a day and finally mentioned above in stackoverflow that IE cannot set cookies for short domain names since 5.0.
So what will happen if it is too short? After the experiment, we found that the cookie cannot be set through javascript for a total of five characters including periods and numbers, but there is a premise, that is, the domain parameter cannot be explicitly specified only when you set the cookie. That is to say, if you write:
ViewSource codePrint the help document. Cookie = "Key = value; domain = AB .cn ";
Cookie setting will fail. If the domain parameter is removed, write it as follows:
View SourceCodePrint the help document. Cookie = "Key = value ";
This problem will not occur, even if the current domain is still AB .cn.
This articleArticleBytes. For more information, see.
Because the cookie setting fails, our traffic monitoring system considers that each access is a new access, and the bounce rate is very high. Ga does not send data if the cookie setting fails.
Firefox and chrome have no such problems.
Mark, hope to help people who encounter similar problems.