+ 6
How to change the colour of border in a table in html ?
I want to change the colour of the border of a table but i don't know how to do it. So if anyone knows then please tell me.
5 Respostas
+ 5
You have to use CSS:
table {
border: solid 1px green; /*1px green border*/
}
(You can use inline styling too)
+ 39
<table border="2" bordercolor="red">
<table border="2" bordercolor="black">
<table border="2" bordercolor="blue">
So on....
+ 5
Thanks
+ 2
If you have to just do the border its easy firstly you have to do basic thing these terms
table
{
}
then put properties in it eg:- if you want border related type in that box border and there are lot of options already available like bordercolor select it and specify your color
table
{
border-color:red;
}
just try to put these words options are already available in it of code playground
Or second method you can apply directly in html file is attribute :-
<table border="2" bordercolor="red" >
<tr>
<td>1<td>
<td>2<td>
</tr>
</table>
- 1
Use CSS