directories and paths

  You are currently not logged in. You can view the forums, but cannot post messages. Log In | Register

16-Jun-17 09:33
I am having a problem with establishing a path to a file when the source is an image, or video. I see root directories, and such, but can't get my head around all that. Anybody got a tutorial on this? What I need is to know what to put in the line of code so the browser goes to the right file and folder. Thanks!

--
Jim Williams
16-Jun-17 14:07
Root relative addressing, which is always the same path no matter where it is called from in the website structure is always prefixed with a slash '/'

So, "/images/filename.ext is a root path to a file in the images folder that is in the root folder.

no leading slash "images/filename.ext" would reference a file in the folder as the document being accessed, as would a leading dot and a slash "./images/filename.ext"

--
Chris.
So long, and thanks for all the fish.
http://webmaster-talk.eu/
16-Jun-17 15:01
Clear as mud!

--
Jim Williams
16-Jun-17 15:43
Okay,

Let's gauge how much you do know.

do you know what either of these are;

Site root, or document root directory?

Document level folder/directory?

--
Chris.
So long, and thanks for all the fish.
http://webmaster-talk.eu/
16-Jun-17 16:43
I have a folder called "HTML", where all my code files are stored. Usually, I go in there when I am writing something in an editor. I first save the work, put down the editor, go to that folder, and right click, and then click "open with". Is that folder the root directory?

--
Jim Williams

 
New posts
Old posts

Follow Elated