halfpizzasupper
Programmer
- Dec 3, 2008
- 1
I have a quick question regarding using HREF and site structure.
I believe that if I have a page which is up one folder from say my stylesheet that I have to include "../" before referencing this but I have saw some sites that do not follow this rule. Can this be set in a config file or something?
i.e.
Say I have the following two folders
[CSS]
[Shop]
Within [Shop] there is my default html page and I need to make a reference to my stylesheet so I use
I was then looking at another site with a similar set up and they simply had
which seemed to work just fine also but I am always having to put the "../".
Not that this is a huge issue, I'm just curious so I can learn! Is it something to do with the file system on the server (i.e. Windows, linux?)
I believe that if I have a page which is up one folder from say my stylesheet that I have to include "../" before referencing this but I have saw some sites that do not follow this rule. Can this be set in a config file or something?
i.e.
Say I have the following two folders
[CSS]
[Shop]
Within [Shop] there is my default html page and I need to make a reference to my stylesheet so I use
Code:
<link rel="stylesheet" type="text/css" href="../css/core.css" media="screen,projection" />
Code:
<link rel="stylesheet" type="text/css" href="/css/core.css" media="screen,projection" />
Not that this is a huge issue, I'm just curious so I can learn! Is it something to do with the file system on the server (i.e. Windows, linux?)