Link Examples

A directory with files and subdirectories with files

The above diagram shows Files and Directories. Level 0 is root level that usually has an index.php file (A). The next level down is Level 1 and is simply a Directory (1) that has four files (B, C, D, and E) in it. The next level down is Level 2 and is another Directory (2) that also had four files (F,G, H, and I) in it.


Let's say you wanted to link A (index.php) down to file C in Directory 1. Your link in file A would be:

href="1/C"
That path means go to Directory 1 and find file C.


Let's say you wanted to link file C back up to file A (index.php) . Your link in file C would be:

href="../A"
That path means go up one directory and find file A (index.php). Note the "../" <-- that means go up one level (one directory)


Let's say you wanted to link file F back up to file A (index.php) . Your link in file F would be:

href="../../A"
That path means go up two directories and find file A (index.php). Note the "../.." <-- that means go up two levels (two directories)


Let's say you wanted to link file H back up to file E. Your link in file H would be:

href="../E"
That path means go up one directory and find file E. Note the "../" <-- that means go up one level. (one directory)


Let's say you wanted to link file B to file E. Your link in file B would be:

href="E"
That path means go and find file E. This path is on the same level.