Skip to content
This repository has been archived by the owner on Dec 5, 2019. It is now read-only.

Halfling font of bootstrap not found anymore #342

Open
UlrichKu opened this issue Mar 3, 2017 · 1 comment
Open

Halfling font of bootstrap not found anymore #342

UlrichKu opened this issue Mar 3, 2017 · 1 comment

Comments

@UlrichKu
Copy link

UlrichKu commented Mar 3, 2017

Starting with version 1.7.0.11 the path for the font "Glyphicons Halflings" in bootstrap is generated with a '//' a the beginning if the variable $_SERVER['DOCUMENT_ROOT'] ends with a '/'.

The resulting https://assets/bootstrap/fonts/glyphicons-halflings-regular.woff is then not found and instead glyph codes displayed by the browser.

It seems to be only a problem of @font-face (with @font-face{ src: url('../fonts/glyphicons-halflings-regular.eot') })

The commit breaking this was: ae5b492

A local workaround is to fix the document root before calling less:
if ('/' === substr($_SERVER['DOCUMENT_ROOT'], -1)) { $_SERVER['DOCUMENT_ROOT'] = substr($_SERVER['DOCUMENT_ROOT'], 0, -1); }

@Asenar
Copy link
Collaborator

Asenar commented Mar 7, 2017

Hi,

what if DOCUMENT_ROOT does not exists (when you use command line for example) ?

Can you make a pull request to add tests/ for this ?

Also, an other workaround would be to define the correct path for @icon-font-path in variables.less

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants