Tell us what’s happening:
Could someone please tell me what im doing wrong. says my class of card needs an id element and have also used spaces and did reset
Your code so far
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<title>XYZ Bookstore Page</title>
</head>
<body>
<h1>XYZ Bookstore</h1>
<p>Browse our collection of amazing books!</p>
<!-- User Editable Region -->
<div class="card-container">
<div class="card">sally-adventure-book</div>
<!-- User Editable Region -->
</div>
</div>
</body>
</html>
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/148.0.0.0 Safari/537.36
Challenge Information:
Build a Bookstore Page - Step 9
GitHub Link: freeCodeCamp/curriculum/challenges/english/blocks/workshop-bookstore-page/68ec9332a9b5b2b32487bd00.md at main · freeCodeCamp/freeCodeCamp · GitHub
ILM
2
the id is not an element, it is an attribute you add to the opening tag, similar to how you did the class attribute
like this?
<div id="card">sally-adventure-book</div>
ILM
4
no, you still need to have class="card" and you need to add the attribute id next to it using the same syntax
Please show me. I’ve been having a real challenge here
ILM
6
let’s just try to write the id attribute first, and later we will think of adding it to the element
do you see here how class="card" is written? this is a class attribute with a value of card
you need to write an id attribute with a value of sally-adventure-book, can you try that?
I attempted this and I just got through
ILM
8
that means you managed to write the correct attribute! that’s great