04.06.2013 Views

Head First HTML with CSS

Head First HTML with CSS

Head First HTML with CSS

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Finding the path from “elixir.html” to “red.jpg”<br />

The elixirs page contains images of several drinks: “red.jpg”,<br />

“green.jpg”, “blue.jpg”, and so on. Let’s figure out the path to<br />

“red.jpg” and then the rest will have a similar path because they<br />

are all in the same folder:<br />

GOAL: we’re in the<br />

beverages folder and we<br />

need to get over to the<br />

images folder.<br />

about<br />

<br />

.<br />

.<br />

.<br />

<br />

directions.html<br />

lounge<br />

beverages<br />

So putting (1) , (2), and (3) together we get:<br />

Up to the<br />

parent folder.<br />

<br />

.<br />

.<br />

.<br />

<br />

lounge.html<br />

<br />

.<br />

.<br />

.<br />

<br />

(1) So we go up to the parent<br />

folder, “lounge”. Remember<br />

this will be written as “..” in<br />

the path.<br />

“/” in between.<br />

elixir.html<br />

Down into<br />

the “images”<br />

folder.<br />

(2) And then down into<br />

the “images” folder.<br />

images<br />

Start here...<br />

“/” in between.<br />

<br />

drinks.gif<br />

.. / images / red.jpg<br />

going further <strong>with</strong> hypertext<br />

green.jpg<br />

blue.jpg<br />

lightblue.jpg<br />

red.jpg<br />

(3) Finally, we find “red.jpg” .<br />

And the file<br />

name itself.<br />

...and find a<br />

path to here.<br />

you are here 67

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!