I have CSS with the following class:
.nav > a::after {
content: \f019;
}
well, \f019 used to show a “down caret” but now it doesn’t, it just shows the box with f019 inside.
What can I look for to get it to display again?
I have CSS with the following class:
.nav > a::after {
content: \f019;
}
well, \f019 used to show a “down caret” but now it doesn’t, it just shows the box with f019 inside.
What can I look for to get it to display again?
It should have quotes around that rule and I assume you have set the font to fontAwesome (or whatever package you are using).
e.g.
a::after {
content: "\f019";
font-family: FontAwesome;
}
I’m sorry I didn’t include the full code. This is my actual block:
.nav > li.menu-item-has-children > a::after {
display: inline-block;
font-family: “fontawesome”;
content: “\f019”;
font-style: normal;
font-weight: normal;
margin-left: 10px;
margin-right: 0;
margin-top: -1px
}
I wonder if I need a certain version of fontawesome. I have 5.12, but this CSS is from an older project. I’ll check that out.
Yes the icons have different codes in different versions so you need to match them up.
The working example I posted is a version 4.7.
You have curly quotes in your code, which won’t work. Make sure you’re not using some kind of word processor to work with code, as they will mess it up. Use a dedicated code editor, like VS Code.
Fontawesome, especially the latest couple of versions of the plugin for Wordpress is too buggy.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.