Please help, Im trying do the tribute page challenge and stuck on items 1 through 7, ad I also feel the instructions are written very poorly I cannnot understand them.
I’ve edited your post for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.
You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.
First off, if you’re using codepen it supplies the boilerplate for you and you only need to put in the elements that would go between the body tags. No need to include the body tags.
If you’re coding somewhere else, you have elements out of order. Review this for an understanding of the HTML boilerplate tags.
You’ve sort of met the first three user stories.
the first element with id="main" is correct
this next has issues. The title element does not go in the body (see the above reference) and you’ve incorrectly assigned an attribute that’s not within the tag. (There’s an extra “>”
I hope I don’t come off as rude, but the instructions are clear to me. They are also broken up into IMO small and easy to work with chunks.
In your code:
Close your <html> tag.
Close your <main> tag, make sure it encloses all your other tags except the </html> closing tag.
Title tag is a metadata tag for setting the tab title in the <head> tag, use a header tag such as <h1> instead, also remove the extra “>”
*Close your <div>
Do the above and you will have completed User Stories 1 through 3
Hi, thankyou, no its ok I just get confused becasue I am new to this language, I have 8/10 now , however I cant seem to make my link work, or to make it 10/10.
type <!doctype html>
<html>
<style>
h1 {
text-align:center;
}
#image-caption {
width: 400px;
}
#img {
max-width:100%;
height:auto;
display: block;
}
.center {
display: block;
margin-left: auto;
margin-right: auto;
width: 50%;
}
</style>
<div id="main">
<h1 id="title"> <u> Elvis Presley- The Legend </u> </h1>
<div id="img-div">
<img class="center" id="image" src="https://media.vanityfair.com/photos/58f1226e50cecc47a7701b89/master/w_2560%2Cc_limit/elvis-presley.jpg" alt="Picture of Elvis" width="20%" height="20%">
<div id="div-caption> "Elvis is a musical legend" ></div-caption>
</div>
<p id= "tribute-info">
<b> Elvis was a great musician</b>
Elvis Aaron Presley (January 8, 1935 – August 16, 1977), also know simply as Elvis, was an American singer, musician and actor. He is regarded as one of the most significant cultural icons of the 20th century and is often referred to as the "King of Rock and Roll" or simply "the King". His energized interpretations of songs and sexually provocative performance style, combined with a singularly potent mix of influences across color lines during a transformative era in race relations, led him to both great success and initial controversy.
</p>
<a id="image-link" target="_blank" href="https://www.youtube.com/watch?v=ixbcvKCl4Jc"></a>
</html>or paste code here
There are HTML coding errors you should be aware of and address. (For now ignore the error about declaring the doctype and the title missing from head. You really need to write HTML with the correct syntax.
You can make it easy on yourself and just make the tribute link a link to a wikipedia page. If you want to add a youtube video then you don’t use the URL of the link. Instead, right click on the video and choose “copy embed code” and paste that into your code.
Just curious, what are you using to write your code?
My personal preference, and recommendation is that you install Visual Studio Code. It is easy to install and will make your code so much more readable. It has tons more features that you can take time to learn as well.