allowtransparency="true" in an iFrame with xhtml transitional doctype

Hi,

I have an iFrame in a page that needs to have

allowtransparency="true"

set to work in IE7. The images displayed in the iFrame are PNGs with transparency and the background is not a solid color. So I really do need this attribute for the page to look correct in IE7.

But I would also like the page to validate with the DOCTYPE:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Is there a way to keep this attribute for IE7 and have a document that passes validation ?

Regards,
howtogetitrightAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

xberryCommented:
allowtransparency is a proprietary attribute that only works with browsers from IE 5.5 and up, so there is
a reason why it doesn't validate, since it is not common browser standard. I personally don't see a way
to have that iframe attribute and same time achieving validation.

Maybe you try a completely different alternative and work with a server side includes that produces the desired
result, thus abandon any iframe use at all.

There is weak spots in common browser standards and usability and the transparency issue sure
is one of them. Let's hope that browser manufacturers will find an agreeable solution with W3C soon.
0
howtogetitrightAuthor Commented:
Hi xberry,

I want to keep the iframe as an iframe. Lets hope someone replies with a solution !

Regards,
0
howtogetitrightAuthor Commented:
I seem to have got it working using conditional comments. So I'll close this question.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Browsers

From novice to tech pro — start learning today.