- Create Account

IEPNGFix working BUT breaking my site's template !!

Forums > IEPNGFix > IEPNGFix working BUT breaking my site's template !!
Author
Message

1) iosoft Group: Members
Posts: 7 Joined: 13 Dec 2007 Location: India IP: 59.93.--.--
Dear Sir,

My site : http://gigahertz.byethost18.com/
Version: both RC4 and RC5.
Configuration: PHP with .HTACCESS with this patch -
http://www.twinhelix.com/cgi-bin/forum.pl/iepngfix/10

The problem -
The FIX is working properly, but the problem is - while loading, the PNGs are stretched.... after loading, the images come back to normal but that stretch causing my template (structure) stays stretched.

As a result, the template designed for '1024' shows horizontal scroll-bar with blanks.

How to solve this ?

2) Angus Turnbull Group: Moderators
Posts: 4042 Joined: 7 Dec 2003 Location: New Zealand IP: 203.109.--.--
Give both a manual HEIGHT and WIDTH to all your images, it solves all sorts of stretching bugs :).

-  Angus.

3) iosoft Group: Members
Posts: 7 Joined: 13 Dec 2007 Location: India IP: 59.93.--.--
It is not possible as my site is a open platform... everyone can post their views and reviews. I can't make sure that everyone will set height and width.

.... any other solution ?
else I have to disable IEPGNFIX itself :(

4) Angus Turnbull Group: Moderators
Posts: 4042 Joined: 7 Dec 2003 Location: New Zealand IP: 202.137.--.--
.iepngfix { behavior....}

<img  class="iepngfix" src="foo.png">

Assign it to specified PNGs only and just let your visitors post normal images if that's a problem. The script can often guesstimate image dimensions OK, particularly inline images in document flow more so than layout/position elements.

- Angus.

5) iosoft Group: Members
Posts: 7 Joined: 13 Dec 2007 Location: India IP: 59.93.--.--
can you tell me why the pictures are 1st expanded and then returning back to its original size ?

can't  it be other way ?
I mean, make the image 1st 0px X 0px and then return it back to original ?

6) Angus Turnbull Group: Moderators
Posts: 4042 Joined: 7 Dec 2003 Location: New Zealand IP: 203.109.--.--
IE is full of random bugs, that's why. I've found that in order to make the script work reliably you have to assign at least one dimension to an image.

- Angus.

7) iosoft Group: Members
Posts: 7 Joined: 13 Dec 2007 Location: India IP: 59.93.--.--
(please take this as suggestion only)

Hi

I found that this solution solves both PNG FIX and PNG Sizing errors.
http://komodomedia.com/blog/index.php/2007/11/05/css-png-image-fix-for-ie

But, it is horribly slow !!

Any  suggestions ?

8) Angus Turnbull Group: Moderators
Posts: 4042 Joined: 7 Dec 2003 Location: New Zealand IP: 203.109.--.--
If you're confident with your layout, and have assigned dimensions to your elements, just remove the dimension-assigning code from my script. It's there to help out the "Why doens't this work?" people who would get otherwise very easily stuck. That script doesn't appear to assign dimensions to images, which makes it a lot simpler.

- Angus.

9) iosoft Group: Guests
IP: 59.93.--.--
Dear Angus,

can you please tell me how can I configure my APACHE server with PHP to support the .HTC file ? what to write in php.ini file ?

I  have tried -
.htaccess ->  no effect.
.php file trick -> distorted image.

As a last chance, I want to make the 'direct server configuration'.

10) Angus Turnbull Group: Moderators
Posts: 4042 Joined: 7 Dec 2003 Location: New Zealand IP: 202.137.--.--
The distorted image is a good sign, it probably means that the script is working and you've just encoutnered a bug :). Try giving your image set width/height and sticking with the PHP approach.

If that doesn't work, post a link here...

- Angus.

11) Alex Group: Guests
IP: 70.83.--.--
Hello!

Some of my PNGs on my website are distorted even if I have a height + width set for them...

See:
www.wolfcast  dot com/news.php

and look for the enveloppe and sitemap icons under the menu near search box...

The komodomedia solution works but would like to stick with yours...

You can contact me here of with the contact form on my site...

Thanks!

12) Angus Turnbull Group: Moderators
Posts: 4042 Joined: 7 Dec 2003 Location: New Zealand IP: 202.137.--.--
Aha, it's the padding-right that does it, it's counted as part of the element and the background stretches to cover it. Switch to margin-right and all should be well!

- Angus.

13) Travis Dahl Group: Guests
IP: 64.37.--.--
You can also set the sizing method to 'image' instead of 'scale' or 'crop' and it will be the same proportions as the original image. Sorry if someone already mrentioned that, didnt see it anywhere else on this forum.

Cheers,
Travis  Dahl
http://www.thedesigncoalition.com[url]

Post a Reply:

You are not logged in, and will be posting anonymously as a guest. If you want to post using an account, please login at the top of this page.