Login to download the latest version of Mint and your favorite Pepper, purchase additional licenses, or post in the Forum. Don't have an account? Create one!

In Partnership with Media Temple

Mint Forum

Loading mint after the dom has fully loaded bad idea?

giom
Minted
Posted on Jul 07, '08 at 04:54 pm

I’m trying to optimize the load time from my webpage tracked by mint and I tried to load mint after the dom and a flash object embedded in the page has fully loaded.

It seems to work and indeed make the page display about 1 second quicker. I’m wondering though if I’m missing something and it’s a bad idea to do that?

I guess I’m probably going to miss hits from people who close the page before it’s fully loaded but well I think I can live with that….

Shaun Inman
Mint/Pepper Developer
Posted on Jul 08, '08 at 08:30 am

While there are no absolutes in anything, I strongly recommend keeping Mint in your document head. If you run into problems the first thing I’m going to tell you is move it back into the document head.

If you decide not to do this, make sure you test in all browsers (and versions of said browsers) frequently used by your visitors. I’m not sure if gradual changes to Mint have worked this out of its system but IE has been known to choke and not render anything when Mint is placed outside of the document head. You might also run into problems with sIFR when Mint is placed outside of the document head (again, only in IE).

giom
Minted
Posted on Jul 08, '08 at 01:42 pm

Ok, thanks for the head up…

I haven’t tested it yet with IE (need to install vmware and play with windows for that yuck :-( ….. ) but before I release my website in the wild I’ll definitely check with a wide range of browsers…

Currently I’m using jquery $(document).ready to load it dynamically… I’ll report back on my browser test later on…

You must be logged in to reply. Login above or create an account