Click here to Skip to main content
16,021,125 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
When I try to add 'dotgreen'as cell data to my table, the cell border disappears. What am i doing wrong? Please help!

Here is the HTML scrap:
 <tr>
             <td>Customisable modular interiors</td>
             <td class="dotorange"></td>   
             <td></td>
             <td></td>
             <td></td>
             <td></td>
             <td class="dotred"></td>   
       </tr> 

Here is the CSS dotgreen property:
.dotgreen{
  height: 2px;
  width: 2px;
  margin-left: 20%;
  margin-right: auto;
  background-color: green;
  border-radius: 50%;
  display: inline-block;
}


What I have tried:

tried increasing the width of the , deecreasing the ball height and width in css.
Posted
Updated 9-Oct-18 6:24am
v2

In HTML your are add class
dotred
but in css your adding
.dotgreen
so i feel css is not call.please change class name.
 
Share this answer
 
The cell border doesn't disappear; it just becomes part of the "dot". You're applying the border-radius to the table cell, so its borders become round.

If you want the dot to appear within the cell, you'll need to apply the class to an element within the cell:
HTML
<td><div class="dotgreen"></div></td>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900