Professional Documents
Culture Documents
3.HTML Program To Create 5 Paragraphs With Different Background Pictures
3.HTML Program To Create 5 Paragraphs With Different Background Pictures
.bg-image2 {
background-image: url('image2.jpg'); /* Replace 'image2.jpg' with your image
file path */
background-size: cover;
color: white; /* Ensuring text is visible against the background */
padding: 20px; /* Adding some padding for better visibility */
}
/* Define similar classes for other images if needed */
</style>
</head>
<body>
<!-- Paragraphs with different background pictures -->
<p class="bg-image1">This is a paragraph with background image 1.</p>
<p class="bg-image2">This is a paragraph with background image 2.</p>
<!-- Add more paragraphs with different background images as needed -->
</body>
</html>