fast as possible guyszz. full steps needed . plz a and b
Answers
Answer:To display square bullets in an unordered list, you can use the CSS list-style-type property. Here is an example of how to do it:
Create an unordered list in HTML, using the ul tag. Each list item should be enclosed in li tags.
Copy code
<ul>
<li>List item 1</li>
<li>List item 2</li>
<li>List item 3</li>
</ul>
In the CSS, target the ul tag and set the list-style-type property to square.
Copy code
ul {
list-style-type: square;
}
Save your HTML and CSS files and open the HTML file in a web browser to see the square bullets.
Alternatively you can also use ::before pseudo-element and content property for the same.
Copy code
li::before {
content: '\25A0';
margin-right: 10px;
}
The above CSS code would insert square bullet character(Unicode) before the list element.
To display text as a fallback if an image cannot be displayed, you can use the alt attribute in the img tag in HTML. The alt attribute is used to provide alternative text that will be displayed if the image cannot be loaded. Here's an example of how to use it:
Copy code
<img src="building.jpg" alt="A picture of a building">
If the image "building.jpg" cannot be displayed, the text "A picture of a building" will be displayed in its place.
You can also use picture and source element, such that if the browser unable to show the image it will show the image with source tag
Copy code
<picture>
<source srcset="building.webp" type="image/webp">
<img src="building.jpg" alt="A picture of a building">
</picture>
This will help to show webp format image if the browser support it and fallback to jpeg if it doesn't.
Additionally, you can use css to style the alt text with ::before and content properties and make it look like image.
Copy code
img::before {
content: attr(alt);
display:block;
background: url(building.jpg);
width: [img-width]px;
height: [img-height]p;
}
Mani
Explanation: