Tell us what’s happening:
It is still saying that my img element should have a display of block and a width of 100%. Also that it should be centered in the parent element. It looks like it already is, I double checked that I used an ID selector and not a class selector, so I’m lost here. Is this a bug or did I make a mistake?
PS: please excuse my dark humor, I got bored and wasn’t expecting to share this haha.
Your code so far
<!-- file: index.html -->
<!DOCTYPE html>
<html lang='en'>
<head>
<meta charset='utf-8'/>
<meta name='viewport' content='width=device-width, initial-scale=1.0'/>
<meta name='description' content='A tribute to the life of the Burgermeister'/>
<title>Burgermeister Tribute</title>
<link rel='stylesheet' href='TributePage.css'/>
</head>
<body>
<main id='main'>
<header>
<h1 id='title'>Burgermeister Meisterburger</h1>
<p>A misunderstood soul</p>
</header>
<figure id='img-div'>
<img id='image' src='BurgermeisterPortrait.jpg'/>
<figcaption id='img-caption'>The great Burgmeister Meisterburger giving his famous speech in Hamburg, Germany in 1939.</figcaption>
</figure>
<div id='tribute-info'>
<h2 class='bold'>A brief history of the life of Burgermeister.</h2>
<ul>
<li>1897 - Born in a small shack in Hamburg, Germany. His parents knew he would be a great leader and changes his name to BurgerMeister.</li>
<li>1902 - Tries his first burger and develops a fondness for the beefy, sesamy-clad sandwich.</li>
<li>1912 - Opens the first burger shack and begins selling hamburgers at never before seen low prices. An obesity epidemic breaks out in Hamburg.</li>
<li>1921 - Begins his epic "Burgers for All" Campaign, as he runs for mayor, winning the hearts of the common citizens. The incumbent administration is protested day and night, the citizens demand that Burgermeister be sworn in.</li>
<li>1922 - Elected mayor of Hamburg in a landslide victory. No one gets any burgers as he hoards them in his mayoral mansion. The townspeople slowly starve under his administration. The first hamburger blackmarket trade begins, along with the rise of violent hamburglars.</li>
<li>1926 - Outlaws playtime for kids in city limits. The public is outraged but the teachers are stoked bro.</li>
<li>1939 - Gives his famous "No More Toymakers to the King" speech. Hitler attended his second appearance at the podium.</li>
<li>1940 - His speech is adapted into a song and used as Nazi propaganda after the word "King" is changed to "Fuhrer." Burgermeister joins the Nazi party shortly after.</li>
<li>1942 - Burgermeister flees to Turkey with his personal S.S. detail. He spends the next 13 years eating only white meat, fearing that his identity may be discovered.</li>
<li>1955 - Commits suicide at the age of 58 to avoid being caught by Israeli Mossad agents. His body is paraded on live TV.</li>
</ul>
<p class='italic'>He was bigger than life itself.. No seriously he was fat, and I mean humongously fat. Like damn bro that's enough burgers, you know people are starving right? In fact he ate so many damn burgers that he had to hire a personal tailor to keep making bigger and bigger pants for his fat ass. I even heard he had to start ordering the fabric in bulk dude!<br /><br />-Annonymous</p>
</div>
<footer>
<a target='_blank' id='tribute-link' href='https://en.wikipedia.org/wiki/Santa_Claus_Is_Comin%27_to_Town_(film)'></a>
</footer>
</main>
</body>
</html>
/* file: styles.css */
html {
font-size: 16px;
}
header {
margin: auto;
text-align: center;
}
#image {
display: block;
max-width: 100%;
height: auto;
}
#img-div {
margin: auto;
text-align: center;
display: flex;
justify-content: center;
flex-direction: column;
}
#tribute-info {
margin: auto;
text-align: left;
width: 60%;
}
h2 {
text-align: center;
}
#tribute-info > ul > li {
margin-bottom: 1em;
}
.bold {
font-weight: 800;
}
.small-text {
font-size: 12px;
}
.subHeading {
margin-top: 0;
}
.italic {
font-style: italic;
}
Your browser information:
User Agent is: Mozilla/5.0 (X11; CrOS x86_64 14541.0.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36
Challenge: Tribute Page - Build a Tribute Page
Link to the challenge: