Does anybody know what the default font family is in a table row element? I need this because I sometimes put a label in td and the label has a different font from the table column and this causes a visual problem. I want to set my label font the same as the default for the td it sits in.
Share
There is no default font in HTML, if none of the font-families specified in CSS are available on the machine of whoever views your code, it will take the default font that person has set in his browser.
That said, you can’t know what font it’ll be unless you explicitly specify it in CSS. It’s recommended to specify a few font-families the
bodytag of your pages to be certain of consistency, with the last one being one of the font-families that are always available in HTML. Your label shoud assume the font given in the CSS for the table row or any parent container, if not, give itsCSS classproperty a value and do it that way.