Computer Applications

Ronaldo, a web designer in a start-up company, wants to give headings in a webpage through <h1> tag. Additionally, he wants to implement following styles on all the <h1> tag of the same webpage at one go.

  • Color-blue
  • Background color-yellow
  • border of the heading - 2px in red

He is not able to implement the above-mentioned additional styles of <h1> tag through regular html code. Suggest him a way out and also help him in writing the code for same.

HTML Intro

32 Likes

Answer

Ronaldo should use CSS (Cascading Style Sheets) to implement the additional styles of <h1> tag.

The HTML code for the same is given below:

<html>
<head>
<style>
    h1 {color: blue; background-color: yellow; border: 2px solid red;}
</style>
</head>
</html>
<body>
<h1>
    Welcome
</h1>
</body>

Answered By

27 Likes


Related Questions