W3cubDocs

/DOM

HTMLTableElement.frame

The HTMLTableElement interface's frame property is a string that indicates which of the table's exterior borders should be drawn.

Syntax

HTMLTableElement.frame = frameSides;

var frameSides = HTMLTableElement.frame;

Parameters

  • fromSides is a string whose value is one of the following values:
    void
    no sides. this is the default.
    "above"
    top side
    "below"
    bottom side
    "hsides"
    top and bottom only
    "vsides"
    right and left sides only
    "lhs"
    left-hand side only
    "rhs"
    right-hand side only
    "box"
    all four sides
    "border"
    all four sides

Example

// Set the frame of TableA to 'border'
var t = document.getElementById('TableA');
t.frame  = "border";
t.border = "2px";

Specification

  • W3C DOM 2 HTML Specification

Browser compatibilityUpdate compatibility data on GitHub

Desktop
Chrome Edge Firefox Internet Explorer Opera Safari
Basic support Yes Yes Yes Yes Yes Yes
Mobile
Android webview Chrome for Android Edge Mobile Firefox for Android Opera for Android iOS Safari Samsung Internet
Basic support Yes ? Yes Yes Yes Yes ?

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/API/HTMLTableElement/frame