Build a Tribute Page- projects

I have to accomplish these two :
" I should see a div element with a corresponding id="img-div" .

User Story #4: Within the img-div element, I should see an img element with a corresponding id="image" ."
I have done the first one and it worked, but I can’t understand the second request!

You should give your image an id = ‘image’

Else post your codepen link here.

...........

where should I place the (id=“image”)?

When a test fails click the red button to see which test(s) are failing and text to help you correct the issue. (Be sure and read more than just the first line of the failing message.)

I am not at the stage of tests yet!

so you have something like

<div id="img-div">
</div>

user story #4 is telling you to nest an img element that has id="image"
in the div element you just created

Edit: here’s a terminology review

HTML tags vs elements vs attributes

HTML tags

Tags are used to mark up the start and end of an HTML element. The following are paragraph tags.
<p></p>

HTML elements

An element in HTML represents some kind of structure or semantics and generally consists of a start tag, content, and an end tag. The following is a paragraph element:
<p>This is the content of the paragraph element.</p>

HTML attributes

An attribute defines a property for an element, consists of an attribute/value pair, and appears within the element’s start tag. An element’s start tag may contain any number of space separated attribute/value pairs.
The most popular misuse of the term “tag” is referring to alt attributes as “alt tags”. There is no such thing in HTML. Alt is an attribute, not a tag.
<img src="foobar.gif" alt="A foo can be balanced on a bar by placing its fubar on the bar's foobar.">

I have something like this:

Al-Khwārizmī
but I don't know where to place the ( id="image")

The following is an example of an html image element:

<img id="image" src="https://x.com/image">

thanks I appreciate your help. I well try it.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.