Hello, I’m stuck on this cert project. I get these 3 errors ,
Failed:Your img element should have a display of block.
Failed:Your #image should have a max-width of 100%.
Failed:Your #image should be centered within its parent.
here is my code:
img {
max-width: 100%;
display: block;
margin: 0 auto;
height: auto;
}
what am I doing wrong? I’ve been stuck on this for over 2 weeks.
<DOCTYPE! html>
<main id="main">
<h1 id="title">Domingo Guillen</h1>
<p>The man who had infinate patience</p>
<figure id="img-div">
<img
id="image"
src="../Bimbo.JPG"
alt="Bimbo y Chicha"
>
<img id="image">
<figcaption id="img-caption">
Bimbo y Chicha sonriendo
</figcaption>
</figure>
<section id="tribute-info">
<h3 id="headline">Bimbo's Timeline:</h3>
<ul>
<li><strong>1942</strong> - Born in Republica Dominicana</li>
<li>
<strong>1988</strong> - Leaves his farm in Sainagua Dominican Republic to come to the USA
</li>
<li>
<strong>2021</strong> - Passed Away
</li>
</ul>
<p>
Bimbo didn't say much but he made it his voice heard.
</p>
<h3>
We love & miss you.
<a
id="tribute-link"
href="https://en.wikipedia.org/wiki/Dominican_Republic"
target="_blank"
>Wikipedia entry</a
>.
</h3>
</section>
</main>
I’ve edited your code for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.
You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.