Unsure what users local settings are but some users get 404 when trying to load chosen-sprite.png and chosen-sprite@2x.png when in SEO-adjusted url that is not root. So for example in domain.com/page/ instead of domain.com/
No 404-error and sprite loaded correctly.
The image files are not loaded and 404-error.
Changing all url() in media/vendor/chosen/css/chosen.css from relative url, like url("chosen-sprite@2x.png"), to absolute url, like url("/media/vendor/chosen/css/chosen-sprite@2x.png"), solves the issue.
Labels |
Removed:
?
|
Labels |
Added:
No Code Attached Yet
|
Labels |
Added:
Information Required
|
No aggregation of css files or nothing like that and I would say that 99% of my visitors do not see issue (neither do I when trying to reproduce) but I have a push notification for all 404-error for logged in users and there are some users who see this issue repeatedly. The same users had 404 error for other images in custom component that was solved the same way.
Since this issue is a vendor file and would probably also occur in core template files I wanted to report what change solved the issue.
Labels |
Removed:
Information Required
|
No aggregation of css files or nothing like that
Are you behind Cloudflare or similar, because the concatenation might happen in the server layer or caching layer, etc?
Nope. Own dedicated server. The few users that have issues might have some local browser plugins or such but haven't got any replies that have helped me localise issue.
Labels |
Added:
bug
|
Are you using any template or plugin that concatenates CSS files? If so then the problem is with those (also as a side comment concatenating CSS/JS files is not anymore considered a best practice, in reality it's an anti pattern).
Also since this is not a problem with the core templates I would suggest closing this @richard67