ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

PNG images in IE

September 19, 2007 5:06pm

Subscribe [5]
  • #1 / Sep 19, 2007 5:06pm

    Dion Snoeijen

    14 posts

    Good evening everybody,

    I am trying to find out how to make png images appear correctly in IE 6.0.
    After looking for a solution on the internet i think i have found onehere.

    i have copied the codes like the site describes.
    and made the .php file lik the site describes.

    Still this doesnt seem to work….
    Does this have anything to do with expression engine?

    And if not, does anybody know a good solution for the .png images in IE??

    Thanx!

    <?php ob_start(); ?>
    
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Triad Design</title>
    
    
    <link href="triad.css" rel="stylesheet" type="text/css" />
    </head>
    
    <body class="oneColFixCtrHdr">
    <div id="container">
    <div id="header-triangle"></div>
    <div id="header">
    </div>
    <div id="mainContent">
    <div id="leftblock-top">
    Bla bla
    </div>
    </div>
    <div id="footer">
    </div>
    </div>
    </body>
    </html>
    
    <?php
        include_once 'replacePngTags.php';
        echo replacePngTags(ob_get_clean());
    ?>
  • #2 / Sep 19, 2007 5:30pm

    rmeder

    97 posts

    Here is a very simple javascript solution that I use.

    Insert:

    <!--[if lt IE 7.]>
    
    <![endif]-->

    into your sites <head></head>

    Then upload pngfix.js to your server.  I have mine in a folder named js (as you will see referenced in the src above).

    You can download pngfix.js here among many other places.  Just google pngfix.js

    Hope this helps.

    Regards,

    Rick

  • #3 / Sep 19, 2007 7:01pm

    grantmx

    1439 posts

    In addition to what rmeder said: All “PNG fixes” that I’ve known of thus far dont work for CSS background images in IE 6 or lesser.  So if you are trying to use a transparent PNG in some CSS, it wont work. 

    Keep that in mind too.

  • #4 / Sep 20, 2007 5:09am

    Dion Snoeijen

    14 posts

    Ok, I will try the pngfix.js.
    Hopefully this works!

    When I have a div with a css style aplied to it, and i place a image with <img

  • #5 / Sep 20, 2007 8:15am

    e-man

    1816 posts

    Another good link to check out in this regard would be Dean Edwards IE7.

  • #6 / Sep 20, 2007 8:55am

    Daniel Walton

    553 posts

    PNG background not working in IE6 you say?

    I’ve used this particular method several times successfully for background images, though admittedly just the filter part and on an IE “lte 6” only external style sheet. It should work back to IE 5.5. Play around with the sizingMethod parameter, possible values are scale, crop and image. More details here.

  • #7 / Sep 20, 2007 11:00am

    grantmx

    1439 posts

    When I have a div with a css style aplied to it, and i place a image with <img

  • #8 / Sep 20, 2007 11:47am

    hothousegraphix

    851 posts

    I’m using a method found here.

    Documentation here.

    This method does in fact support transparent background images in IE6. I’ve used this process on my last three projects. It works without fail.

  • #9 / Sep 20, 2007 12:21pm

    grantmx

    1439 posts

    Fresh!  Thanks guys. I will give these a try.

  • #10 / Sep 20, 2007 2:55pm

    Dion Snoeijen

    14 posts

    Thanks, I have enough to try!
    Really annoying IE doesnt support it by itself!

  • #11 / Sep 20, 2007 3:08pm

    Dion Snoeijen

    14 posts

    Ok! the solution of hothousegraphix works great!
    Also for the background images!
    Thanks to all of you.

  • #12 / Sep 29, 2007 3:21pm

    grantmx

    1439 posts

    How about repeating background transparent PNG images?  I just tried hothousegraphix fix, and it works, but my repeating background image is not repeating in IE6.  Is there a work around that anybody found?

    I think that was my long standing issue before…as opposed to just background images with all of these PNG fixes.

  • #13 / Nov 05, 2007 11:00am

    kirkaracha

    273 posts

    bgsleight lets you use PNGs as background images in IE.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases