What is difference between background-color and bgcolor? | SoloLearn: Learn to code for FREE!


What is difference between background-color and bgcolor?

Please help me

1/23/2021 2:19:34 PM

Shyam Kumar

2 Answers

New Answer


bgcolor is an old HTML attribute which is not supported in HTML5. Do not use it in HTML5 documents. background-color is a CSS property used in style sheets and replaces the bgcolor attribute in HTML5. See: https://www.w3schools.com/tags/ref_attributes.asp https://www.w3schools.com/cssref/pr_background-color.asp


Shyam Kumar Your question appears to a duplicate please use the searchbar before asking. Please use the forum guidelines provided below and use the 8 rules for getting help from the community. https://www.sololearn.com/Blog/38/8-simple-rules-to-get-help-from-the-community Your question will be reviewed by the mod-team and mostly likely will be marked for deletion. Reason duplicate threads are removed to: Focus substantially similar discussion in one thread and to prevent forums being cluttered with multiple threads on the same topic. https://www.sololearn.com/Discuss/1316935/?ref=app https://www.sololearn.com/discuss/529/?ref=app https://www.sololearn.com/discuss/974075/?ref=app https://www.sololearn.com/discuss/742989/?ref=app https://www.sololearn.com/discuss/2674991/?ref=app https://www.sololearn.com/discuss/1936901/?ref=app https://www.sololearn.com/discuss/1142088/?ref=app https://www.sololearn.com/discuss/4907/?ref=app