Answer the question
In order to leave comments, you need to log in
Why is the base tag not working in ModX Revo?
Hello.
On the site, some of the styles (the styles of the 1st screen) are inserted into the head inline. It's all right here.
The 2nd part of the styles is connected as usual, with an external css file. Here, despite the tag set in the head, the calculation of the paths comes from the folder where the .css file itself is located.
Example:
the .css file itself is located along the path site.ru/assets/files/style.css
It has an image connection style: background: #fff url('../assets/files/img/top_bg2.jpg') no- repeat center center
On the site we get:
site.ru/assets/files/assets/files/img/img.jpg
- the path /assets/files/ is duplicated
- the calculation is based on the location path of the .css file
I would remove the /assets/files/ path from the image url and no problem. But if this css is connected inline in the head, then everything works as it should - the calculation comes from the root. With or without base.
How to bring to a common denominator? What is the configuration or connection error? ..
PS friendly urls are included, of course
Answer the question
In order to leave comments, you need to log in
Lead the path to the image from the root url('/assets/files/img/top_bg2.jpg')
.
And so it is clear that the relative path in css is relative to the location of css.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question