@ font-face {
font-family: "myfont";
src: url ("../fonts/myfont.eot?#iefix") format ("embedded-opentype"),
url ("../fonts/myfont.woff2") format ("woff2"),
url ("../fonts/myfont.woff") format ("woff"),
url ("../fonts/myfont.ttf") format ("truetype"),
url ("../fonts/myfont.svg # myfont") format ("svg");
}
In ScssParser, on line 137 or 139 the file could not be found and the generated path is incomplete.
On line 142, if the typo3 url is like "http://localhost/mysite/", the browser searches for the file in "http://localhost/mysite/mysite/typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf ", because the generated path ismysite/typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf (line 142) and becomes ../../../../mysite/typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf (line 155).
To resolve these two bugs, here is the code from line 136
The generated path is then from the root path typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf , then becomes after preg_replace ../../../../typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf
Bug Report
Prerequisites
Description
With a scss code like this:
In ScssParser, on line 137 or 139 the file could not be found and the generated path is incomplete. On line 142, if the typo3 url is like "http://localhost/mysite/", the browser searches for the file in "http://localhost/mysite/mysite/typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf ", because the generated path is
mysite/typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf
(line 142) and becomes../../../../mysite/typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf
(line 155).To resolve these two bugs, here is the code from line 136
The generated path is then from the root path
typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf
, then becomes after preg_replace../../../../typo3conf/ext/my_theme/Resources/Public/fonts/myfont.ttf