English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
This article introduces the HTML dialog open attribute, which is a boolean (boolean) attribute. After using this attribute, the specified dialog element is in an active state, and the user can interact with it. The online instance demonstrates how to use the HTML dialog open attribute, browser compatibility, syntax definition, and detailed information about its attribute values.
Usage of <dialog> element:
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>HTML <dialog> open Attribute Usage-Basic Tutorial(oldtoolbag.com)</title> <style>table, th, td { border: 1px solid black;/style> </head> <body> <table> <tr> <th>January <dialog open> This is an open dialog window</dialog></th> <th>February</th> <th>March</th> </tr> <tr> <td>31</td> <td>28</td> <td>31</td> </tr> </table> </body> </html>Test and see ‹/›
IEFirefoxOperaChromeSafari
Currently only Chrome and Safari 6 Supports the open attribute.
The open attribute is a boolean (boolean) attribute.
After using this attribute, the specified dialog element is in an active state and the user can interact with it.
<dialog> tag is HTML5 New tags.
In XHTML, attributes are not allowed to be abbreviated, the open attribute must be defined as: <dialog open="open">.
<dialog open>