Tribute Page - Build a Tribute Page

Tell us what’s happening: Hi, I keep getting the max-width: 100% and the display property of block wrong and it wont accept my code. I’m confused and not sure what the problem is.

Describe your issue in detail here.

Your code so far

<!-- file: index.html -->
<!DOCTYPE HTML>
<html lang="en">
  <body>
    <head>
      <title id="title">Dr. Ova May</title>
      </head>
      <main id="main">
        <div id="heading">
<h1>Dr. Ova May</h1>
<p>The women who saved the world</p>
        </div>
<div id="img-div">
<img id="image" width="100%">
<div id="img-caption">Dr. Ova May in her lab</div>
        </div>
        <h2 id="tribute-info">Here's a time line of Dr. May's life:</h2>
        <ul>
          <li>1994: Born in Kwanda</li>
          <li>2012: Graduated High school</li>
        <li>2020: Graduated first in her class at Medical school</li>
        <li>2023: Finds the cure for cancer</li> 
        </ul>
        <a href="styles.css" link rel="stylesheet" id="tribute-link" target="_blank">
          
      </main>
      <footer>
        <p>For more info on her life visit@www.DrOvaMay.com</p>
        </footer>
      </body>
  </html>
/* file: styles.css */
#image {
  max-width:100%;
  height: auto;
  display: block
}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/119.0.0.0 Safari/537.36

Challenge Information:

Tribute Page - Build a Tribute Page

You appear to have created this post without editing the template. Please edit your post to Tell us what’s happening in your own words.
Learning to describe problems is hard, but it is an important part of learning how to code.
Also, the more you say, the more we can help!

you need to link you styles.css ,put the link in the <head> of your HTML

<link rel="stylesheet" type="text/css" href="styles.css">
1 Like

Tell us what’s happening: Hi, I dont understand the display property being blocked in this project. When I add display: blocked on the CSS it says the project has failed. I dont understand why it is failing. It also says the image should be max-width: 100% in #image but when I insert that under #image it says project has failed

Describe your issue in detail here.
Hi, I dont understand the display property being blocked in this project. When I add display: blocked on the CSS it says the project has failed. I dont understand why it is failing. It also says the image should be max-width: 100% in #image but when I insert that under #image it says project has failed

Your code so far

<!-- file: index.html -->
<!DOCTYPE HTML>
<html lang="en">
  <body>
    <head>
      <meta charset="UTF-8">
      <title id="title">Dr. Ova May</title>
      </head>
      <main id="main">
        <div id="heading">
<h1>Dr. Ova May</h1>
<p>The women who saved the world</p>
        </div>
<div id="img-div">
<img id="image" width="100%">
<div id="img-caption">Dr. Ova May in her lab</div>
        </div>
        <h2 id="tribute-info">Here's a time line of Dr. May's life:</h2>
        <ul>
          <li>1994: Born in Kwanda</li>
          <li>2012: Graduated High school</li>
        <li>2020: Graduated first in her class at Medical school</li>
        <li>2023: Finds the cure for cancer</li> 
        </ul>
        <a href="styles.css" link rel="stylesheet" id="tribute-link" target="_blank">
          
      </main>
      <footer>
        <p>For more info on her life visit@www.DrOvaMay.com</p>
        </footer>
      </body>
  </html>
/* file: styles.css */
#image {
  max-width:100%;
  height: auto;
  display: block
}

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/119.0.0.0 Safari/537.36

Challenge Information:

Tribute Page - Build a Tribute Page

You appear to have created this post without editing the template. Please edit your post to Tell us what’s happening in your own words.
Learning to describe problems is hard, but it is an important part of learning how to code.
Also, the more you say, the more we can help!

Hello @Ovie2!

Thank you for posting both the code and problem for us!

I do not see any actual image within your code.

This may be why the code is failing.

If there is an online picture of the person, I would suggest attempting to connect the link to your code

If there is not any image, you may wish to use something from one of the free sites, such as a group of people signifying the people she has saved.

I hope this helps you!

If you still need help, please post on this post for further help?

Keep up the good progress!

Thank you so much @Gray.n.Grey . I had tried creating a link but yhe image was not opening but I will try again and come back here if I need any more help.

1 Like

I hope it works, but if it is not working.

One thing to note is that it is not possible to use a local (one from your device) picture, unless it is first uploaded to a hosting site.

If you are not worried about sharing it, I use pexels for my photos. Other people have access to use them which is fine because they are not personal photos.

I hope this helps you @Ovie2 !

If not, as a community, we look forward to helping you!

1 Like

link you styles.css in the HTML

1 Like

As mentioned in the previous post, the <link rel="stylesheet href="styles.css"> is missing from within the head.

As well, please move the opening <body> tag below the closing </head> tag?

There is still a need for an image to work with in the img, as you realized on your own.

Keep up the great progress!

2 Likes