How to add Images? Image appears broken?

#1

Ok, so I am completely new to coding and I am just trying to add images to my project. I thought I could add a new folder and just drag and drop but realized this software doesn’t allow that. So I found the file and copy and pasted it into my project folder? Is that how you do it? Well, it worked and I could see a preview of it but when I added it to my code it appears broken. What am I doing wrong?

49%20PM

0 Likes

#2

It lets me do it. Maybe I’m special? :slight_smile:

What does this mean? Specifically, added it to my code.

0 Likes

#3

Here is my other screenshot.

0 Likes

#4

Atom has no support to drag an image from the tree-view into your code

0 Likes

#5

I mean when I added it to the folder I created called img on the left and then typed the image into my code here it doesn’t work.

0 Likes

#6

I realize that but what is the step by step process on the best way to add an image or even my own photos. I have no idea how to do it correctly it seems.

0 Likes

#7

What’s wrong with what you have? Everything looks fine to me.

0 Likes

#8

You need img/ at the start of each path. The browser is looking in the same folder as the HTML file and finding nothing.

0 Likes

#9

what is src?? and alt??

0 Likes

#10

There’s plenty of help available online about HTML elements like img.

0 Likes