This forum is now read-only. Please use our new forums! Go to forums
HTML links and images
i cann’t use image url or web url….pls help me..
Answer 535ec48680ff334c94000317
(1)
To embed an image in an HTML page we use the img tag:
<img
(2)
Then we use the image source attribute src
:
<img src="
(3) now we write the address of the image. You know it is a valid address if it ends with .jpg or .gif or .png:
<img src="http://s3.amazonaws.com/codecademy-blog/assets/f3a16fb6.jpg"
(4) Finally we apply the closing tag />
or just >
. Make sure there is a "
just before it:
<img src="http://s3.amazonaws.com/codecademy-blog/assets/f3a16fb6.jpg" />
And if all goes well it will look like this:
As for links…
A link starts with <a href="
Then we add the http://
part
Then the address: www.facebook.com">
Now we add a title:
<a href="http://www.facebook.com">
Google
and finally close it </a>
:
<a href="http://www.facebook.com">
Google/a>
hope it helps!
New addition:
About: " ... at least one of my images also has to be a link?
‘
This is a link, right?
<a href="http://www.facebook.com">Google/a>
Instead of the title (Google) We could put a url to an image. Let’s place the above image as a link:
<a href="http://www.facebook.com"><img src="http://s3.amazonaws.com/codecademy-blog/assets/f3a16fb6.jpg" </a>
Popular free courses
- Free Course
Learn SQL
In this SQL course, you'll learn how to manage large datasets and analyze real data using the standard data management language.Beginner friendly,4 LessonsLanguage Fluency - Free Course
Learn JavaScript
Learn how to use JavaScript — a powerful and flexible programming language for adding website interactivity.Beginner friendly,11 LessonsLanguage Fluency - Free Course
Learn HTML
Start at the beginning by learning HTML basics — an important foundation for building and editing web pages.Beginner friendly,6 LessonsLanguage Fluency
3 comments
What does it mean when it says that at least one of my images also has to be a link?
Hi Jenna, I have added more information at the very bottom of my previous message that addresses your question.
Thanks I figured it out myself after getting frustrated.