You are here: Reference > HTML > attributes > ALLOWTRANSPARENCY (frame, iframe)

ALLOWTRANSPARENCY attribute (frame, iframe)

Browser support:
9
Sets whether a frame element (frame or iframe) can be transparent.
The support for the ALLOWTRANSPARENCY attribute has been removed in Internet Explorer 9.
Transparency is allowed by default for linked documents in all commonly used browsers, except in Internet Explorer before version 9. If the ALLOWTRANSPARENCY attribute is not specified, the linked document cannot be transparent. If the ALLOWTRANSPARENCY attribute is set, the linked document can be transparent and it will be transparent by default (see background-color).
JavaScript page for this attribute: allowTransparency. You can find other example(s) there.

Possible values:

This attribute has no values.
Specifying the ALLOWTRANSPARENCY attribute with an arbitrary value has the same effect as specifying it with no value.
For example, all of the following declarations have the same effect: allowtransparency, allowtransparency="true", allowtransparency="false", allowtransparency="on", allowtransparency="allowtransparency".
Although Boolean attributes may be used with no value in HTML, for XHTML compatibility, always use the ALLOWTRANSPARENCY attribute in the following format: allowtransparency="allowtransparency".

Example HTML code 1:

This example illustrates the use of the ALLOWTRANSPARENCY attribute:
Code
transparent.htm
<body style="background:#EFEFFF">
    <iframe src="transparent.htm" allowtransparency="allowtransparency">
    </iframe>
</body>
Did you find this example helpful? yes no

Supported by tags:

Related pages:

External links:

User Contributed Comments

Post Content

Post Content