Home » HTML5CSS3 » Adding Image at the bottom of Heading with CSS

Adding Image at the bottom of Heading with CSS

You want to place a repeating image at the bottom of a heading, like the cloud as shown below:

Use the background-image, background-repeat, and background-position properties:
h2 {
font: bold italic 2em Georgia, Times, "Times New Roman", serif;
background-image: url(anyimage.jpg);
background-repeat: repeat-x;
background-position: bottom;
border-bottom: 10px solid #666;
margin: 10px 0 0 0;
padding: 0.5em 0 60px 0;
}