html - Relative paths not valid for embedding fonts with CSS? -


i'm trying embed font, way css generated fontsquirrel, relative path:

@font-face {     font-family: 'myfontfamily';     src: url('config/templates/fonts/myfont.eot');     src: url('config/templates/fonts/myfont.eot?#iefix') format('embedded-opentype'),      url('config/templates/fonts/myfont.woff') format('woff'),      url('config/templates/fonts/myfont.ttf') format('truetype'),      url('config/templates/fonts/myfont.svg#myfont') format('svg');     font-weight: normal;     font-style: normal; } 

this not seem work.

changing /base/config/templates/fonts... fixes problem, sake of application, preferable use relative paths.

the font files do exist relative document using them.

are relative paths font importing not acceptable? what's going on here?

change to:

./config/templates/fonts/... 

or in cases:

../config/templates/fonts/... 

depending on structure.


Comments