Style tableLayout Özellik
Örnek
Sabit bir tablo düzeni ayarlayın:
document.getElementById("myTable").style.tableLayout = "fixed";
Tanım ve Kullanım
tableLayout özelliği, tablo hücrelerini, satırları ve sütunları yerleştirmenin yolunu ayarlar veya döndürür.
Tarayıcı Desteği
Property | |||||
---|---|---|---|---|---|
tableLayout | Yes | Yes | Yes | Yes | Yes |
Sözdizimi
tableLayout özelliğini döndürün:
object.style.tableLayout
tableLayout özelliğini ayarlayın:
object.style.tableLayout = "auto|fixed|initial|inherit"
Mülk değerleri
Value | Description |
---|---|
auto | Column width is set by the widest unbreakable content. This is default.
|
fixed | Column width is set by the width of table and columns (not the content of the cells)
|
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Teknik detaylar
Varsayılan değer: | Oto |
---|---|
Geri dönüş değeri: | Bir tablo için kullanılan tablo düzeni algoritmasını temsil eden bir Dize |
CSS Sürümü | CSS2 |
Daha fazla örnek
Örnek
Tablo düzenini döndür:
alert(document.getElementById("myTable").style.tableLayout);
İlgili Sayfalar
CSS eğitimi: CSS Tablosu
CSS referansı: tablo düzeni özelliği
❮ Stil Nesnesi