Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HTML / CSS table with GRIDLINES

how do I display the gridlines in a HTML table? (am using IE6)

like image 880
Allan Bowe Avatar asked Nov 19 '09 12:11

Allan Bowe


People also ask

How do you add lines to a table in CSS?

When you use CSS to add borders to tables, it only adds the border around the outside of the table. If you want to add internal lines to the individual cells of that table, you need to add borders to the interior CSS elements. You can use the HR tag to add lines inside individual cells.

How do I add a grid to a table?

Click the table. Click the Table Layout tab, and then under Settings, click Gridlines.

How do I show grid lines in CSS?

You can turn on the grid button located in the div which has display: grid declared. All you have to do is go to your browser's developer tools (mine is Microsoft Edge which is based on Chromium). You will see a button like this. And then you can code and test as you wish.

How do you add lines to a table in HTML?

To create table border in HTML, the border attribute was used. But the introduction of HTML5, deprecated the border tag. Create table border using the CSS property border. Set table border as well as border for <th> and <td>.


1 Answers

Via css. Put this inside the <head> tag.

<style type="text/css" media="screen">  table{ border-collapse:collapse; border:1px solid #FF0000; }  table td{ border:1px solid #FF0000; } </style> 
like image 62
pixeline Avatar answered Sep 23 '22 08:09

pixeline