HtmlIFrameElement Class
https://html.spec.whatwg.org/multipage/iframe-embed-object.html#htmliframeelement
public sealed class HtmlIFrameElement : HtmlElement- Inheritance
HtmlElementHtmlIFrameElement
Properties
| Name | Description |
|---|---|
| Align | Gets or sets the value of the align content attribute. |
| Allow | Gets or sets the value of the allow content attribute. |
| AllowFullscreen | Gets or sets a value indicating whether the element has the allowfullscreen content attribute. |
| ContentDocument | https://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-contentdocument |
| ContentWindow | https://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-contentwindow |
| Credentialless | https://wicg.github.io/anonymous-iframe/#dom-htmliframeelement-credentialless: the documents of a credentialless iframe are loaded without credentials and are not subject to the embedder policy of the parent document. |
| Csp | Gets or sets the value of the csp content attribute (https://w3c.github.io/webappsec-cspee/#dom-htmliframeelement-csp): a policy that the documents loaded into the iframe must enforce (CSP Embedded Enforcement). A valid value is sent in the Sec-Required-CSP header of the requests of the navigations of the iframe, and a response that does not accept it (with an Allow-CSP-From header, or with policies at least as strict) is blocked. |
| FrameBorder | Gets or sets the value of the frameborder content attribute. |
| Height | Gets or sets the value of the height content attribute. |
| Loading | Gets or sets the value of the loading content attribute, limited to the known values (the canonical keyword, or the default value). |
| LongDesc | Gets or sets the longdesc content attribute, as a URL resolved against the base URL of the document. |
| MarginHeight | Gets or sets the value of the marginheight content attribute. |
| MarginWidth | Gets or sets the value of the marginwidth content attribute. |
| Name | Gets or sets the value of the name content attribute. |
| PermissionsPolicy | Gets the policy object of the iframe (https://w3c.github.io/webappsec-permissions-policy/#dom-htmliframeelement-permissionspolicy): the features that a document loaded into the iframe would be allowed to use, according to the permissions policy of the document of the iframe and to its allow, allowfullscreen, src, srcdoc and sandbox attributes. |
| Policy | Gets or sets the value of the policy content attribute (https://wicg.github.io/document-policy/#iframe-policy-attribute): the document policy that the documents loaded into the iframe must declare (Document Policy). It is combined with the required policy of the document of the iframe, and sent in the Sec-Required-Document-Policy header of the requests of the navigations of the iframe; a response whose Document-Policy header is not compatible with it is blocked. |
| ReferrerPolicy | Gets or sets the value of the referrerpolicy content attribute, limited to the known values (the canonical keyword, or the default value). |
| Sandbox | Gets the tokens of the sandbox content attribute. |
| Scrolling | Gets or sets the value of the scrolling content attribute. |
| Src | Gets or sets the src content attribute, as a URL resolved against the base URL of the document. |
| Srcdoc | https://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-srcdoc |
| Width | Gets or sets the value of the width content attribute. |
Align
HtmlElements.g.csGets or sets the value of the align content attribute.
public string Align { get; set; }Allow
HtmlElements.g.csGets or sets the value of the allow content attribute.
public string Allow { get; set; }Property value
See also
AllowFullscreen
HtmlElements.g.csGets or sets a value indicating whether the element has the allowfullscreen content attribute.
public bool AllowFullscreen { get; set; }ContentDocument
NavigableContainers.cshttps://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-contentdocument
public Document? ContentDocument { get; }ContentWindow
NavigableContainers.cshttps://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-contentwindow
public Window? ContentWindow { get; }Credentialless
HandWrittenReflection.cshttps://wicg.github.io/anonymous-iframe/#dom-htmliframeelement-credentialless: the documents of a credentialless iframe are loaded without credentials and are not subject to the embedder policy of the parent document.
public bool Credentialless { get; set; }Property value
See also
Gets or sets the value of the csp content attribute (https://w3c.github.io/webappsec-cspee/#dom-htmliframeelement-csp): a policy that the documents loaded into the iframe must enforce (CSP Embedded Enforcement). A valid value is sent in the Sec-Required-CSP header of the requests of the navigations of the iframe, and a response that does not accept it (with an Allow-CSP-From header, or with policies at least as strict) is blocked.
public string Csp { get; set; }FrameBorder
HtmlElements.g.csGets or sets the value of the frameborder content attribute.
public string FrameBorder { get; set; }Property value
See also
Height
HtmlElements.g.csGets or sets the value of the height content attribute.
public string Height { get; set; }Property value
See also
Loading
HtmlElements.g.csGets or sets the value of the loading content attribute, limited to the known values (the canonical keyword, or the default value).
public string Loading { get; set; }Property value
See also
LongDesc
HtmlElements.g.csGets or sets the longdesc content attribute, as a URL resolved against the base URL of the document.
public string LongDesc { get; set; }Property value
See also
MarginHeight
HtmlElements.g.csGets or sets the value of the marginheight content attribute.
public string MarginHeight { get; set; }Property value
See also
MarginWidth
HtmlElements.g.csGets or sets the value of the marginwidth content attribute.
public string MarginWidth { get; set; }Property value
See also
Gets or sets the value of the name content attribute.
public string Name { get; set; }Property value
See also
PermissionsPolicy
HandWrittenReflection.csGets the policy object of the iframe (https://w3c.github.io/webappsec-permissions-policy/#dom-htmliframeelement-permissionspolicy): the features that a document loaded into the iframe would be allowed to use, according to the permissions policy of the document of the iframe and to its allow, allowfullscreen, src, srcdoc and sandbox attributes.
public PermissionsPolicy PermissionsPolicy { get; }Policy
HandWrittenReflection.cs- Experimental (WEBPLATEXP0016)
Gets or sets the value of the policy content attribute (https://wicg.github.io/document-policy/#iframe-policy-attribute): the document policy that the documents loaded into the iframe must declare (Document Policy). It is combined with the required policy of the document of the iframe, and sent in the Sec-Required-Document-Policy header of the requests of the navigations of the iframe; a response whose Document-Policy header is not compatible with it is blocked.
[Experimental("WEBPLATEXP0016", UrlFormat = "https://github.com/meziantou/Meziantou.Framework/blob/main/src/Meziantou.Framework.WebPlatform/docs/experimental-apis.md#{0}")]
public string Policy { get; set; }ReferrerPolicy
HtmlElements.g.csGets or sets the value of the referrerpolicy content attribute, limited to the known values (the canonical keyword, or the default value).
public string ReferrerPolicy { get; set; }Sandbox
HtmlElements.g.csGets the tokens of the sandbox content attribute.
public DomTokenList Sandbox { get; }Scrolling
HtmlElements.g.csGets or sets the value of the scrolling content attribute.
public string Scrolling { get; set; }Property value
See also
Gets or sets the src content attribute, as a URL resolved against the base URL of the document.
public string Src { get; set; }Property value
See also
Srcdoc
HandWrittenReflection.cshttps://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-srcdoc
public string Srcdoc { get; set; }Property value
Exceptions
TypeErrorException- Trusted Types are enforced and the default policy did not convert the value.
See also
Width
HtmlElements.g.csGets or sets the value of the width content attribute.
public string Width { get; set; }Property value
See also
Methods
| Name | Description |
|---|---|
| GetSvgDocument() | https://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-getsvgdocument |
| SetSrcdoc(TrustedHtml) | The srcdoc setter with a TrustedHtml value (https://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-srcdoc). |
GetSvgDocument()
NavigableContainers.cshttps://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-getsvgdocument
public Document? GetSvgDocument()SetSrcdoc(TrustedHtml)
HandWrittenReflection.csThe srcdoc setter with a TrustedHtml value (https://html.spec.whatwg.org/multipage/iframe-embed-object.html#dom-iframe-srcdoc).
public void SetSrcdoc(TrustedHtml value)