thanks for that script. there is another bug related to the max selectors one. its that IE can only handle 31 css files includes via . is this script handling that problem too? it should scan an html file for to many includes and replace them with <style>@import</style> each style tag can contain up to 31 css files.