+ 1

Is there a simpler way to make a background without using the <table> element/css?

Whenever I want to make a closed off background for whatever text I'm typing, I usually use the <table> element. For example: If I want to make white text with a black background around it, I'd type something similar to this: ——— <table bgcolor="#000000"> <td><font color="#ffffff>My Text Here</font></td> </table> ——— Is there a more simplified way of making text with their own background around it? Maybe there's an attribute I don't know about?

24th Dec 2022, 8:03 AM
MishaG4mer
MishaG4mer - avatar
3 odpowiedzi
+ 3
you can use the STYLE attribute and CSS to customize your text or other elements for example <p style="color:white; background-color:black;"> I am a text! </p> has the same effect except without those borders Learn more about what you can do with elements in the CSS course on Sololearn!
24th Dec 2022, 8:54 AM
Vanessa Nilsson
+ 1
Thanks :)
24th Dec 2022, 9:01 AM
MishaG4mer
MishaG4mer - avatar
0
Maybe you are studying a very old textbook or tutorial...nobody do this anymore...
25th Dec 2022, 6:28 AM
Bob_Li
Bob_Li - avatar