K
ksamdev
Hi,
I have a site of next structure:
js/...
css/...
img/...
pages/1/index.html
pages/1/img/...
The idea is that page
pages/1/index.html
uses some js,css,img from top folders and at the same time has a
number of images to be picked up from
pages/1/img/
folder. So, I tried to use BASE tag in head and specify path to my
site:
<base href='http://site'>
so that JS, CSS, etc. would be picked up in HEAD with LINK tag using
relative path. Very nice especially if I use another relative paths in
my JS scripts say for images.
But problem arises in index.html whenever I try to use any images from
pages/1/img
folder. There is a huge number of them and each time I specify
ABSOLUTE path which is definitely not a best solution. I'd like to use
at the same time relative to current page folder paths for these
resources.
Is there any way to use relative paths with BASE tag specified for JS,
CSS, etc. and somehow link local files from page folder at the same
time?
I have a site of next structure:
js/...
css/...
img/...
pages/1/index.html
pages/1/img/...
The idea is that page
pages/1/index.html
uses some js,css,img from top folders and at the same time has a
number of images to be picked up from
pages/1/img/
folder. So, I tried to use BASE tag in head and specify path to my
site:
<base href='http://site'>
so that JS, CSS, etc. would be picked up in HEAD with LINK tag using
relative path. Very nice especially if I use another relative paths in
my JS scripts say for images.
But problem arises in index.html whenever I try to use any images from
pages/1/img
folder. There is a huge number of them and each time I specify
ABSOLUTE path which is definitely not a best solution. I'd like to use
at the same time relative to current page folder paths for these
resources.
Is there any way to use relative paths with BASE tag specified for JS,
CSS, etc. and somehow link local files from page folder at the same
time?