Updated
As I am looking at this more and more. If I utilize the http protocol for my includes within my php files rather than ../ this should solve my issue. This is more of a php question than a CSS question. Please move this to the appropriate forum with a different header. That would be PHP relative includes vs. PHP absolute includes. Original
I have a minor issue.
I am using relative locations (ie. ../)for my images found within my CSS file.
This has been working great as long as I keep everything I do in the root directory. I started utilizing different directories to keep my code in and found out that the further I go away from the root directory the more issues I am starting to have utilizing the above method. (This goes the same for my JS file directory)
Problem
Reference the chart below The problem that is happening is when the public directory attempts to access the css file it looks for the css file as support/css/css.css rather than root/css/css.css
I utilize multiple include files and have massive amounts of code to make everything on the website work together so I cannot re-write everything and start over again.
Objective
Without rewriting everything and moving everything into different directories, I would like to be able to utilize the same php include files and the same CSS, JS, Image files, etc so that when I make a change to the website I only have to do so in 1 file to make it site wide.
Example:
Root Directory has the following directories:
(You will notice that in the Root there is are CSS, JS, Images and Support Directories. You will also notice there is a Public Directory located within the Support directory. This is where the issues is at.)
Root
¦
CSS --> All Images Referenced as ../Images/
JS
Images
Support --> Public --> References A CSS.PHP file as ../../css.php
A portion of the contents of the CSS.PHP are:
<link rel="stylesheet" type="text/css" href="../css/css.css" />
I thought about utilizing absolute references but by personal preference would like to stick to relative references.
What do you think?
Any ideas?