Jump to content

  • Log In with Google      Sign In   
  • Create Account

Images


Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.


  • You cannot reply to this topic
1 reply to this topic

#1 KailiKame   Members   -  Reputation: 414

Like
0Likes
Like

Posted 29 July 2014 - 08:14 PM

I have an image that i'm using as a header on a website so, i need it to appear on each page. I got the image to appear on the home page. However, when I copy and pasted the code for the image, it doesn't appear on the net page. Is there some rule about using the image twice? is their a better way to go about doing this?

 

<div>
<img src="../IMG/logo.png" alt="Summer Employment Experience logo" width="100%"/>
</div>
 


#2 DiegoSLTS   Members   -  Reputation: 2113

Like
1Likes
Like

Posted 29 July 2014 - 08:47 PM

There's no rule about it, if the image is in the right place it should be displayed. Use the tools on your browser to check where is it looking for the image, it looks like a simple problem with the resulting URL that's used to request the actual image. Check the URL of the working image and the the URL of the broken one and you'll found how to fix it.

 

Consider that "../IMG/logo.png" means that the image path is built relative to the html file location, so, if you have your html file at "<path>/src" folder then the image should be in "<path>/IMG" folder, but it could depend on other stuffs too (like the base tag or some stuffs that frameworks might do).


Edited by DiegoSLTS, 29 July 2014 - 08:52 PM.





Old topic!

Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.




PARTNERS