(replace xxxx-xx with your Google Analytics account number)
The new code passes W3c XHTML 1.0 strict compliance verification,
mitigates Nested Script errors on ASP on IIS, and installs on Blogger
and will be the default code provided within the Google Analytics
interface.
Thanks to everyone who both reported the issue and suggested fixes!
> (replace xxxx-xx with your Google Analytics account number)
> The new code passes W3c XHTML 1.0 strict compliance verification,
> mitigates Nested Script errors on ASP on IIS, and installs on Blogger
> and will be the default code provided within the Google Analytics
> interface.
> Thanks to everyone who both reported the issue and suggested fixes!
Why does Google not validate their code before publishing? The lack of
conformance with the W3C is causing troubles for some products, as
this case shows.
Why not hide javascript from old browsers (and fussy validators) using
the comments hack? It would save all the unescaping. At least it seems
to be accepted by blogger. Not sure if it works (generates data)
though.
i.e.
<script>
<!-- hide javascript
...
// end hide -->
</script>
> (replace xxxx-xx with your Google Analytics account number)
> The new code passes W3c XHTML 1.0 strict compliance verification,
> mitigates Nested Script errors on ASP on IIS, and installs on Blogger
> and will be the default code provided within the Google Analytics
> interface.
> Thanks to everyone who both reported the issue and suggested fixes!
> Why not hide javascript from old browsers (and fussy validators) using
> the comments hack? It would save all the unescaping. At least it seems
> to be accepted by blogger. Not sure if it works (generates data)
> though.
> i.e.
> <script>
> <!-- hide javascript
> ...
> // end hide -->
> </script>
> On Dec 19, 8:39 am, AnalyticsPro wrote:
> > If you're having issues installing the ga.js on either an ASP site or
> > Blogger, please use the following code instead:
> > (replace xxxx-xx with your Google Analytics account number)
> > The new code passes W3c XHTML 1.0 strict compliance verification,
> > mitigates Nested Script errors on ASP on IIS, and installs on Blogger
> > and will be the default code provided within the Google Analytics
> > interface.
> > Thanks to everyone who both reported the issue and suggested fixes!
I've added the new-new GA code, as posted above, to our site and it
returns two errors: "_gat not defined" and "Error: unterminated string
literal.... Source Code:var gaJsHost = (("https:" ==
document.location.protocol) ? "https://".
What would the correct version look like for a HTTP site that is XHTML
1.0 Transitional? We are not running Blogger or ASP and still having
problems tracking/validating.
I had a similar problem when cutting and pasting the code that one of
the strings was split over 2 lines. make sure there are no extra
newlines in the code you have.
> I've added the new-new GA code, as posted above, to our site and it
> returns two errors: "_gat not defined" and "Error: unterminated string
> literal.... Source Code:var gaJsHost = (("https:" ==
> document.location.protocol) ? "https://".
> What would the correct version look like for a HTTP site that is XHTML
> 1.0 Transitional? We are not running Blogger or ASP and still having
> problems tracking/validating.
> (replace xxxx-xx with your Google Analytics account number)
> The new code passes W3c XHTML 1.0 strict compliance verification,
> mitigates Nested Script errors on ASP on IIS, and installs onBlogger
> and will be the default code provided within the Google Analytics
> interface.
> Thanks to everyone who both reported the issue and suggested fixes!
> > (replace xxxx-xx with your Google Analytics account number)
> > The new code passes W3c XHTML 1.0 strict compliance verification,
> > mitigates Nested Script errors on ASP on IIS, and installs onBlogger
> > and will be the default code provided within the Google Analytics
> > interface.
> > Thanks to everyone who both reported the issue and suggested fixes!
i tried this but googleanalytics still says that the monitoring code
has not been detected, i paid attention to put it where asked and
checked it after copy-paste. what else could be the problem? (on
blogger)
> (replace xxxx-xx with your Google Analytics account number)
> The new code passes W3c XHTML 1.0 strict compliance verification,
> mitigates Nested Script errors on ASP on IIS, and installs onBlogger
> and will be the default code provided within the Google Analytics
> interface.
> Thanks to everyone who both reported the issue and suggested fixes!
> i tried this but googleanalytics still says that the monitoring code
> has not been detected, i paid attention to put it where asked and
> checked it after copy-paste. what else could be the problem? (on
> blogger)
> On 19 Dic 2007, 00:39, AnalyticsPro wrote:
> > If you're having issues installing the ga.js on either an ASP site orBlogger, please use the following code instead:
> > (replace xxxx-xx with your Google Analytics account number)
> > The new code passes W3c XHTML 1.0 strict compliance verification,
> > mitigates Nested Script errors on ASP on IIS, and installs onBlogger
> > and will be the default code provided within the Google Analytics
> > interface.
> > Thanks to everyone who both reported the issue and suggested fixes!
> That message does not go away immediately. If the code is installed
> correctly the message will go away after a few hours, or sometimes up
> to 48 hours.
> On Feb 16, 2:45 pm, pilly wrote:
> > i tried this but googleanalytics still says that the monitoring code
> > has not been detected, i paid attention to put it where asked and
> > checked it after copy-paste. what else could be the problem? (on
> >blogger)
> > On 19 Dic 2007, 00:39, AnalyticsPro wrote:
> > > If you're having issues installing the ga.js on either an ASP site orBlogger, please use the following code instead:
> > > (replace xxxx-xx with your Google Analytics account number)
> > > The new code passes W3c XHTML 1.0 strict compliance verification,
> > > mitigates Nested Script errors on ASP on IIS, and installs onBlogger
> > > and will be the default code provided within the Google Analytics
> > > interface.
> > > Thanks to everyone who both reported the issue and suggested fixes!
> > That message does not go away immediately. If the code is installed
> > correctly the message will go away after a few hours, or sometimes up
> > to 48 hours.
> > On Feb 16, 2:45 pm, pilly wrote:
> > > i tried this but googleanalytics still says that the monitoring code
> > > has not been detected, i paid attention to put it where asked and
> > > checked it after copy-paste. what else could be the problem? (on
> > >blogger)
> > > On 19 Dic 2007, 00:39, AnalyticsPro wrote:
> > > > If you're having issues installing the ga.js on either an ASP site orBlogger, please use the following code instead:
> > > > (replace xxxx-xx with your Google Analytics account number)
> > > > The new code passes W3c XHTML 1.0 strict compliance verification,
> > > > mitigates Nested Script errors on ASP on IIS, and installs onBlogger
> > > > and will be the default code provided within the Google Analytics
> > > > interface.
> > > > Thanks to everyone who both reported the issue and suggested fixes!