dd_belatedpng is undefined – IE6 Javascript Error

I’ve started using DD_belatedPNG to fix transparent PNG’s in Internet Explorer 6 for my Web Design Projects. However I had this little error occurring on each page load:

dd_belatedpng is undefined

The problem was that I had included the script:

<!–[if lt IE 7 ]>
<script src=”/globals/js/dd_belatedpng.js”></script>
<script> DD_belatedPNG.fix(‘img, .png_bg’); //fix any <img> or .png_bg background-images </script>

In the <head> area of my code, essentially triggering straight away – what you need to do is include the above script just before your closing </body> tag and everything should be fine!

Your Internet Explorer 6 sites now look that tiny bit better!

Exit mobile version