We can use normal CSS to make changes in the table, here we will be using border property to give spacing between different tbody elements.
No prior and deep knowledge is required it is just basic CSS and HTML trick.
Note: Only thing to be noted is that there must be one “tr” tag inside the tbody tag.
Example 1: The code that uses the border-top property to give the spacing between the elements is given below.
Example 2: In the below given example we have used Before selector property. This has helped in giving a margin between the tbody elements so the code for this is given below. Also we have used overflow:hidden property in the table to prevent overflow of before element.
- How to add space (" ") after an element using :after selector in CSS ?
- How to remove the space between inline-block elements?
- Space between two rows in a table using CSS?
- How to set space between the flexbox ?
- How to set vertical space between the list of items using CSS ?
- How to increase the space between dotted border dots using CSS?
- jQuery | Add Elements with Examples
- Program to replace every space in a string with hyphen
- Clone a stack without extra space
- CSS | white-space Property
- How to make a div fill a remaining horizontal space using CSS?
- How to tab space instead of multiple non-breaking spaces (nbsp)?
- How to remove gutter space for a specific div in Bootstrap ?
- How to put images in a box without space using Bootstrap?
- Binary Space Partitioning
- How To Add Google Maps With A Marker to a Website
- How To Add Google Translate Button On Your Webpage?
- How to Add Google Charts on a Webpage?
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.