Font Awesome - Getting Others to See in Output

This forum is for all Flare issues related to styles, stylesheets and XML.
Post Reply
M_Mercer2015
Propeller Head
Posts: 22
Joined: Fri Jan 22, 2016 8:57 am

Font Awesome - Getting Others to See in Output

Post by M_Mercer2015 »

Hello! I've managed to successfully add Font Awesome to my project. I installed the fonts on my machine. I added the code to my master page.

The icons rendered in the topic preview and build. I could also see them in the output after I published. However, no one else can see the icons in the published output.

I've temporarily linked to the content delivery network. This resolves the problem for now, but for a long term resolution we want the fonts embedded in the project.

MASTER PAGE
============
<?xml version="1.0" encoding="utf-8"?>
<html xmlns:MadCap="http://www.madcapsoftware.com/Schemas/MadCap.xsd" MadCap:lastBlockDepth="8" MadCap:lastHeight="177" MadCap:lastWidth="1456">
<head>
<link href="../../Resources/Stylesheets/Styles.css" rel="stylesheet" type="text/css" />
<!-- <link rel="stylesheet" href="../../AwareHelp/FontAwesome/css/font-awesome.min.css" /> -->
<!-- Temporary resolution below - link to CDN via the script from Font Awesome. -->
<script src="https://use.fontawesome.com/b99a84a9d8.js"></script>
</head>
<body>

I'm using Flare 12 2016r2 and Font Awesome 4.7.

Help?
NorthEast
Master Propellus Maximus
Posts: 6426
Joined: Mon Mar 05, 2007 8:33 am

Re: Font Awesome - Getting Others to See in Output

Post by NorthEast »

What output are you creating - HTML5, PDF?

If you want to use Font Awesome in a HTML5 help target, then you don't install the fonts in Windows.
The project/target needs to include:
* the CSS (with the font-face definitions)
* the font files (that the CSS links to)
M_Mercer2015
Propeller Head
Posts: 22
Joined: Fri Jan 22, 2016 8:57 am

Re: Font Awesome - Getting Others to See in Output

Post by M_Mercer2015 »

Thank-you for your response. :)

My output is HTML5 Top Nav.

I created a FontAwesome folder in my content folder, it has two sub folders, css and fonts. See attached screenshot.

So I should uninstall the fonts from my machine?
You do not have the required permissions to view the files attached to this post.
NorthEast
Master Propellus Maximus
Posts: 6426
Joined: Mon Mar 05, 2007 8:33 am

Re: Font Awesome - Getting Others to See in Output

Post by NorthEast »

Yes, uninstall FontAwesome from Windows.

In your master page, remove the comment so it links to font-awesome.min.css in your project.
And comment/remove the link to the CDN.

My guess is that you have set a master stylesheet in your target. If you do this, when Flare builds the target it only includes a link to the master stylesheet in the output topics, and doesn't include links to any other stylesheets, like your link to font-awesome.min.css.

To fix this (in v12 or 2016r2), open your target's General tab, and if you have set a Master Stylesheet, make sure that you also select Allow local stylesheets.
M_Mercer2015
Propeller Head
Posts: 22
Joined: Fri Jan 22, 2016 8:57 am

Re: Font Awesome - Getting Others to See in Output

Post by M_Mercer2015 »

Thank-you.

I uninstalled the font and changed my master page

<head>
<link href="../../Resources/Stylesheets/Styles.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" href="../../AwareHelp/FontAwesome/css/font-awesome.min.css" />
<!--
Temporary - link to CDN via the script from Font Awesome.
<script src="https://use.fontawesome.com/b99a84a9d8.js"></script>
-->
</head>

On the General tab of my target I selected the "Allow local stylesheets" check box.

Now....
I still see the icons in Flare and in the topic preview, but the formatting got all messed up.

The format is wonky in the output as well *and* the icons are not visible.

??? I'm so close, yet so far. :(
You do not have the required permissions to view the files attached to this post.
Post Reply