diff options
-rw-r--r-- | askbot/templates/base.html | 1 | ||||
-rw-r--r-- | askbot/templates/meta/fonts.html | 23 | ||||
-rw-r--r-- | askbot/templates/meta/html_head_stylesheets.html | 7 |
3 files changed, 16 insertions, 15 deletions
diff --git a/askbot/templates/base.html b/askbot/templates/base.html index 63d7115f..7000c0ac 100644 --- a/askbot/templates/base.html +++ b/askbot/templates/base.html @@ -13,6 +13,7 @@ <link rel="shortcut icon" href="{{ settings.SITE_FAVICON|media }}" /> {% block before_css %}{% endblock %} {% include "meta/html_head_stylesheets.html" %} + {% include "meta/fonts.html" %} {% block forestyle %}{% endblock %} {% include "meta/html_head_javascript.html" %} {% block forejs %}{% endblock %} diff --git a/askbot/templates/meta/fonts.html b/askbot/templates/meta/fonts.html index e8e54a8f..1e0fe707 100644 --- a/askbot/templates/meta/fonts.html +++ b/askbot/templates/meta/fonts.html @@ -1,8 +1,15 @@ -<style type="text/css"> -@font-face { - font-family: 'Open Sans Condensed'; - font-style: normal; - font-weight: 700; - src: url('{{"/images/OpenSans-CondBold.ttf"|media}}'); -} -</style> +{% if settings.USE_LOCAL_FONTS %} + {# this version is for serving fonts locally - e.g. for intranet sites #} + <style type="text/css"> + @font-face { + font-family: 'Open Sans Condensed'; + font-style: normal; + font-weight: 700; + src: url('{{"/images/OpenSans-CondBold.ttf"|media}}'); + } + </style> +{% else %} + {# note: for IE8 we ask for fonts separately #} + <link href='//fonts.googleapis.com/css?family=Open+Sans+Condensed:700&subset=latin-ext' rel='stylesheet' type='text/css'> + <link href='//fonts.googleapis.com/css?family=Open+Sans+Condensed:700&subset=cyrillic-ext' rel='stylesheet' type='text/css'> +{% endif %} diff --git a/askbot/templates/meta/html_head_stylesheets.html b/askbot/templates/meta/html_head_stylesheets.html index 85bb489c..23750239 100644 --- a/askbot/templates/meta/html_head_stylesheets.html +++ b/askbot/templates/meta/html_head_stylesheets.html @@ -9,13 +9,6 @@ <script type="text/javascript" src="{{"/js/less.min.js"|media}}"></script> {% endif %} <link href="{{'/bootstrap/css/bootstrap.css'|media}}" rel="stylesheet" type="text/css" /> -{% if settings.USE_LOCAL_FONTS %} - {% include "meta/fonts.html" %} -{% else %} - {# note: IE8 fix - a combined font link wont work so we have two #} - <link href='http://fonts.googleapis.com/css?family=Open+Sans+Condensed:700&subset=latin-ext' rel='stylesheet' type='text/css'> - <link href='http://fonts.googleapis.com/css?family=Open+Sans+Condensed:700&subset=cyrillic-ext' rel='stylesheet' type='text/css'> -{% endif %} {{ skin.get_extra_css_link() }} {% if settings.USE_CUSTOM_CSS %} <link |