<img src="images/logo.gif" />
is equivalent to
<img src="./images/logo.gif" />
But
<img src="/images/logo.gif" />
is different.
Where is the third item looking for logo.gif?
<img src="images/logo.gif" />
is equivalent to
<img src="./images/logo.gif" />
But
<img src="/images/logo.gif" />
is different.
Where is the third item looking for logo.gif?
The third one is looking relative to the root of the site, so if you were on a page at:
http://entrian.com/somewhere/page.html
it would look in:
http://entrian.com/images/logo.gif
ignoring the somewhere
piece of the page's address.
images/logo.gif
It's relative and means: Go to a folder called images and then get the resource logo.gif
./images/logo.gif
It's relative and means: From the current folder (the dot means this) go to a folder called images and then get the resource logo.gif
As you can see the first two mean the same, finally the last one
/images/logo.gif
It's absolute and means: From the root of the web server or the file system or whatever (the slash means this) go to a folder called images and then get the resource logo.gif