Hello!
I've been working on a customized web site framework in
PHP/javascript/
CSS, and I'm having trouble due to the fact that I'm insistng on a specific directory structure:
/ - web site root
/includes - includes directory
/includes/images - images directory: all web site images are stored here
/includes/scripts - directory containing javascripts
/includes/styles - stylesheet directory
The /includes/styles directory has various stylesheets (one for web, one for printing, etc.) It also has a ul2menu.
css file for the main menu.
The /includes/scripts directory has a file called ul2menu.
js which controls the main menu.
I also have the follwing directories which is where I'm having trouble calling the images, scripts, and stylesheets correctly:
/Articles - Contains articles for my customers to view
/Products - Contains the product pages
/Services - Contains services pages.
/Support - contains support pages
when I use a
php in the root dir, which calls the ul2menu
JS and
CSS, it works fine, but a file in the /Articles directory, for example, will fail to call the
CSS and
JS correctly. How can I setup
PHP to call the files under includes regardless of what directory I'm in? I've tried using relative and full URLs with no luck, and I've tried calling it as a path o the server as well.
The customized ul2menu is called by /includes/Header.inc.
php, which calls scripts/ul2menu.
js and styles/ul2menu.
css correctly from any
PHP file in the root directory, but fails to call them correctly when in /Articles, /Support, etc. I know how to create variables in
PHP and call them, but it's just not working for me. Any ideas?
Thanks in advance!
Riley