benjaminkott / bootstrap_package

Bootstrap Package delivers a full configured theme for TYPO3, based on the Bootstrap CSS Framework.
https://www.bootstrap-package.com/
MIT License
336 stars 202 forks source link

Images in less files #658

Open chequille opened 5 years ago

chequille commented 5 years ago

Hi Benjamin, following problem: I do have some css classes in a less file where background images are defined. But less is doing something strange with the path given in the url( ). Do not know how to fix this. Example: background-image: url('fileadmin/theme/hopfengut/Resources/Public/Images/schmuck_unten_40.png') no-repeat;

Result: background-image: url("../../../../typo3conf/ext/hopfengut/Resources/Public/Less/Theme/fileadmin/theme/hopfengut/Resources/Public/Images/schmuck_unten_40.png");

Any idea how to get this working? Best regards, Jürgen

PS: Using Typo 8.7.x and your latest version of bootstrap_package

gilbertsoft commented 4 years ago

Hi @chequille You should not use the fileadmin folder for your templates, create a sitepackage instead see https://www.sitepackagebuilder.com/ The less and sccs compilers always using the theme folder as relative starting point as you can see in the generated URL. You can try to use an absolute path of your images by adding a prepending slash.