Tell us what’s happening:
hi, doing the business card lab. now not liking a couple of the elements. how to fix.
Your code so far
<!-- file: index.html -->
<!DOCTYPE html>
<html lang="en">
<head>
<link rel="stylesheet" href="styles.css" />
<meta charset="UTF-8">
<title>Digital Business Card</title>
</head>
<body>
<div class="business-card">
<img class="profile-image" src="https://cdn.freecodecamp.org/curriculum/labs/flower.jpg" alt="A vibrant flower in full bloom">
<img src="https://cdn.freecodecamp.org/curriculum/labs/flower.jpg" alt="A vibrant flower in full bloom />"
<p class="full-name">Marvin Hunkin</p>
<p class="designation">SoftwEare Developer</p>
<p class="company">@freeCodeCamp</p>
<hr>
<p>Email: hunkinmarvin5@gmail.com</p>
<p>Phone: (123) 456-789</p>
<hr>
<a href="">Portfolio</a>
<hr>
<div class="social-media">
<a href="https://www.twitter.com">Twitter</a>
<a href="https://www.linkedin.com">LinkedIn</a>
<a href="https://www.github.com">GitHub</a>
<h2>Connect with me</h2>
</div>
</div>
</body>
</html>
/* file: styles.css */
body {
background-color: rosybrown;
font-family: Arial, sans-serif;
}
p {
margin-top: 5px;
margin-bottom: 5px;
}
a {
text-decoration: none;
}
.business-card {
width: 300px;
background-color: lightgreen;
padding: 20px;
margin-top: 100px;
text-align: center;
font-size: 16px;
margin-left: auto;
margin-right: auto;
}
.profile-image {
max-width: 100%;
}
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/137.0.0.0 Safari/537.36
Challenge Information:
Design a Business Card - Design a Business Card
https://www.freecodecamp.org/learn/full-stack-developer/lab-business-card/design-a-business-card`hi. okay well was able to then get the two editors. the css is fine. the couple of parts in the html, complaining about the p tags class element for full name and something else. so will paste the list of the test. did copy from the editor to visual studio code, and then copied from visual studio code back to the editor. so, what am i doing wrong. is there any extra characters or or any other things that jaws is not picking up. so will paste the error test list and my html. so only two errors in the html, no errors in the css. any help.
marvin.
ps: pasting below.
Menu
Profile
Instructions
index.htmlEditorstyles.cssEditor
ConsoleHide the previewPreviewMove the preview to a new window and focus it
Design a Business Card
Build an app that is functionally similar to this example project. Try not to copy the example project, give it your own personal style.
Fulfill the user stories below and get all the tests to pass to complete the lab.
User Stories:
- You should link the style sheet
styles.cssusing thelinktag in theheadsection of the HTML file. - Your page background should be
rosybrown. The overall font should beArial, with a fallback ofsans-serif. - All of the
pelements should have a top and bottommarginof5px. - All links on the page should not be underlined.
- You should have a
divwith aclassattribute with a value ofbusiness-cardthat will contain all the other elements. - The
.business-cardselector should have properties to set the element as300pxwide and a background color of your choice. Also you should set apaddingof20pxall around and a topmarginof100px. The text should be center aligned and the font size should be16px. The left and right margins should be set toauto. - Inside the
.business-cardelement, there should be animgelement with aclassattribute with a value ofprofile-image. You can set the image source tohttps://cdn.freecodecamp.org/curriculum/labs/flower.jpgif you like. There should be analtwith a meaningful description. - The
.profile-imageselector should have amax-widthproperty with a value of100%. - Inside the
.business-cardelement, after theimgelement, you should have threepelements with aclassattribute that has, respectively, a value offull-name,designation, andcompany. - The first
pelement should contain your name. - The second
pelement should contain your designation. - The third
pelement should have your company name. - There should be an
hrelement below the thirdpelement. - After the
hrelement, there should be twopelements. In the firstpelement, you should have an email address as the text. In the secondpelement, the text should be a phone number. After the twopelements, there should be anaelement with the textPortfoliolinking to a valid URL. Add anhrelement after theaelement containing the portfolio link. - You should have another
divelement with aclassattribute with a value ofsocial-media. Within this element, there should be anh2element with the textConnect with me. - Inside the
.social-mediaelements, there should be threeaelements. Theaelements should have the textTwitter,LinkedInandGitHubrespectively with links to valid websites.
Run the Tests (Ctrl + Enter)Reset this lesson
Get Help
Tests
-
Passed:1. Your
linkelement should be within yourheadelement. -
Passed:2. Your
linkelement should have arelattribute with the valuestylesheet. -
Passed:3. Your
linkelement should have anhrefattribute with the valuestyles.css. -
Passed:4. You should set the page background color in the
bodyselector torosybrown. -
Passed:5. You should set the page font to
Arialin thebodyelement with a fallback ofsans-serif. -
Passed:6. Your
pelements should have a top and bottommarginof5px. -
Passed:7. The links of the page should have no underline.
-
Passed:8. You should have one main
divwith aclassattribute with a value ofbusiness-card. -
Passed:9. Your
.business-cardselector should have awidthproperty with a value of300px. -
Passed:10. Your
.business-cardselector should have abackground-colorproperty with a valid color value. -
Passed:11. Your
.business-cardselector should have apaddingproperty with a value of20px. -
Passed:12. Your
.business-cardselector should have a top margin of100px. -
Passed:13. The text inside the
.business-cardelement should be center-aligned. -
Passed:14. The font size of the text inside the
.business-cardelement should be16px. -
Passed:15. The left and right margins of the
.business-cardelement should be set toauto. -
Passed:16. Inside the
.business-cardelement, there should be animgelement with aclassattribute with a value ofprofile-image. -
Passed:17. The image source should be set to a valid image.
-
Passed:18. The
altattribute of the image should be set to a meaningful description. -
Passed:19. Your
.profile-imageselector should have amax-widthproperty with a value of100%. -
Failed:20. Inside the
.business-cardelement, after theimgelement, there should be apelement with aclassattribute with a value offull-name. -
Passed:21. After the
.full-nameelement, there should be apelement with aclassattribute with a value ofdesignation. -
Passed:22. After the
.designationelement, there should be apelement with aclassattribute with a value ofcompany. -
Failed:23. The first
pelement, the one with class offull-name, should contain your name. -
Passed:24. The second
pelement, the one with aclassattribute ofdesignation, should contain your designation. -
Passed:25. The third
pelement, the one with theclassattribute with a value ofcompany, should contain your company name. -
Passed:26. After the third
pelement, the one with theclassattribute with a value ofcompany, there should be anhrelement. -
Passed:27. After the first
hrelement, there should be apelement with an email address as your text. -
Passed:28. After the email
pelement, there should be anotherpelement with a phone number as your text. -
Passed:29. After the phone number
pelement, there should be anaelement with the textPortfolio -
Passed:30. Your portfolio
aelement should have a validhref. -
Passed:31. After the
aelement containing your portfolio, there should be anotherhrelement as a divider. -
Passed:32. After the second
hrelement, there should be adivelement with aclassattribute with a value ofsocial-media. -
Passed:33. Inside the
.social-mediaelement, there should be anh2element with the textConnect with me. -
Passed:34. Inside the
.social-mediaelement there should be threeaelements. -
Passed:35. The first
aelement should have the textTwitter. -
Passed:36. The
hrefof the firstaelement should point to a valid link. -
Passed:37. The second
aelement should have the textLinkedIn. -
Passed:38. The
hrefof the secondaelement should point to a valid link. -
Passed:39. The third
aelement should have the textGitHub. -
Passed:40. The
hrefof the thirdaelement should point to a valid link.
24
25
26
27
28
29
com">LinkedIn
<a href="https:/
/www.github.
com">GitHub
Connect with
me
22
23
24
25
26
27
28
29
margin-left: auto;
margin-right: auto;
}
.
profile-image {
max-width: 100%;
}
// running tests 20. Inside the
.business-card
element, after the
img
element, there should be a
p
element with a
class
attribute with a value of
full-name
. 23. The first
p
element, the one with class of
full-name
, should contain your name. // tests completed
Navigated to Design a Business Card
Digital Business Card `
<img src="https://cdn.freecodecamp.org/curriculum/labs/flower.jpg" alt="A vibrant flower in full bloom />"