HTML5 MathML
HTML5 MathML frame Attribute
The frame attribute on the <mtable> element draws a border around the entire table. It accepts none, solid or dashed to control the outer frame of a matrix or aligned system.
Definition and Usage
Use frame to outline a MathML table. It affects only the outer border; use rowlines and columnlines to draw interior separators. Values are none (no border, the default), solid or dashed.
Values
| Value | Effect |
|---|---|
| none | No border (default). |
| solid | A solid border around the table. |
| dashed | A dashed border around the table. |
Example
Example
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>MathML frame attribute</title>
</head>
<body>
<math display="block">
<mtable frame="solid">
<mtr>
<mtd><mn>1</mn></mtd>
<mtd><mn>0</mn></mtd>
</mtr>
<mtr>
<mtd><mn>0</mn></mtd>
<mtd><mn>1</mn></mtd>
</mtr>
</mtable>
</math>
</body>
</html>⚠️
Table framing attributes have uneven support in MathML Core. For dependable borders, wrap the <math> in an element styled with a CSS border, or style the table with CSS.
Key Takeaways
- frame draws an outer border around an <mtable>.
- Values are none, solid and dashed.
- Support is uneven - CSS borders are a reliable fallback.
