- Сообщений: 10
- Спасибо получено: 0
Twitter-инструментарий на Ruby on Rails
Виджет amoCRM: экспорт данных в Google Docs
Alternative caching Joomla module
API Яндекс Метрика и Highcharts
JavaScript SELECT. Динамические списки
Extended weather informer. Weather Underground
Снова про курс валют Центробанка, про cross-origin и джаваскрипты
jTriad contact form - контактная форма для Joomla
jExchange rates CBR, модуль Joomla 3
Joomla: интернет-магазин без VirtueMart. K2Store
jWeather by ip. Погода по ip для Joomla!
CSV Improved. Настройка импорта из csv-файла в VirtueMart
Подарок бухгалтеру, или КЛАДР для Community Builder
Joomla и SuperJob: вакансии по API
@font-face {
font-family: 'Name of Font';
src: url('/path-to/font-file.file-extension')
}
Пожалуйста Войти или Регистрация, чтобы присоединиться к беседе.
app/assets/fonts
font-url
@font-face {
font-family: 'Font_Name';
src: font-url('Font_Name.ttf');
}
Пожалуйста Войти или Регистрация, чтобы присоединиться к беседе.
yotson пишет: Хотя следую совету продвинутой девушки по ссылке:
@font-face {
font-family: 'Name of Font';
src: url('/path-to/font-file.file-extension')
}
You have two main options here:
1. Update the path request:
So use /assets/amaze.ttf instead of /fonts/amaze.ttf.
Be aware that in order for the path /assets/fonts/amaze.ttf to work you would need to put the amaze.ttf font in /app/assets/fonts/fonts/ or /vendor/assets/fonts/fonts/. The double fonts directory ensures there is a fonts directory in /public/assets after the assets are compiled. See this answer for more info.
2. Move your fonts directory to your public directory:
Since the requested path doesn't utilize the Asset Pipeline anyway, you can simply move your fonts directory to the /public/ directory and the web server will automatically serve it. So your font(s) should be located at /public/fonts/amaze.ttf, etc.
That should do it!
Пожалуйста Войти или Регистрация, чтобы присоединиться к беседе.
Masterpro.ws © 2009 - 2020 Ruby and PHP Development. Web Studio