- This topic has 24 replies, 3 voices, and was last updated 5 years, 5 months ago by Tom.
-
AuthorPosts
-
October 21, 2018 at 10:32 pm #706877Adam
Hello,
I am trying to use some of the latest font awesome icons, in particular this bone icon and this cookie icon.
I have the code snippet to load the latest font awesome library and all my other icons are showing up:
add_action( 'wp_enqueue_scripts', 'tu_load_font_awesome' ); /** * Enqueue Font Awesome. */ function tu_load_font_awesome() { wp_enqueue_style( 'font-awesome', '//use.fontawesome.com/releases/v5.3.1/css/all.css', array(), '5.3.1' ); }
Am I missing something here, why don’t these two icons show up?
Thank you,
October 22, 2018 at 6:12 am #707143DavidStaffCustomer SupportHi there,
do you have a link to the Site? And are other FA 5.0 icons rendering?
October 23, 2018 at 8:24 pm #708721AdamHi David,
I tried a bunch of other icons that I believe are from FA 5.0 and they all worked.
My website is in a staging area and requires a log in to view. Where would I privately send the password?
Thank you,
October 24, 2018 at 2:30 am #708870DavidStaffCustomer SupportYou can use the Account Issue form:
https://generatepress.com/contact/
Please add a link to this topic
October 25, 2018 at 5:33 am #710056DavidStaffCustomer SupportHi there,
i got the login thank you. But i am seeing a huge amount of shortcodes displayed on the site. Have you de-activated a plugin that is required? Sorry difficult to diagnose the FA issue with the way it looks at the moment. Let me know
October 25, 2018 at 2:45 pm #710572AdamHey David,
Sorry about all the shortcode mess, that was all left over code after I uninstalled the Avada theme and installed generatepress. I have removed it all now but the bone fontawesome still does not appear on the main menu, beside the word chow.
In the menu section I believe I added it properly like the other icons that are displaying properly:
<i class="fa fa-bone menu-icon"></i>Chow
Let me know if you think of any possible reasons, thanks a lot for your help.
October 25, 2018 at 3:59 pm #710605DavidStaffCustomer SupportYou’re site is running FA 4.7 which doesnt have the bone or the cookie icon.
Have you added any FA plugins as well as the code ?October 25, 2018 at 4:11 pm #710611AdamHey David,
Oh my bad the only thing I added was the code, `add_action( ‘wp_enqueue_scripts’, ‘tu_load_font_awesome’ );
/**
* Enqueue Font Awesome.
*/
function tu_load_font_awesome() {
wp_enqueue_style( ‘font-awesome’, ‘//use.fontawesome.com/releases/v5.3.1/css/all.css’, array(), ‘5.3.1’ );`I thought that was fetching the latest FA icons for me. Do I need to use a FA plugin as well as that code?
October 25, 2018 at 4:45 pm #710625DavidStaffCustomer SupportNo – that script should be all you need.
I also checked to make sure BeaverBuilder wasn’t loading FA 4 – its not.Where did you add that script?
October 25, 2018 at 5:03 pm #710635AdamI added it to the snippets plug in, the snippet is called “Load Font Awesome Icons”. Was that the correct place?
October 25, 2018 at 5:10 pm #710638DavidStaffCustomer SupportOk, replace it with this snippet:
add_action( 'wp_enqueue_scripts', 'tu_load_font_awesome' ); /** * Enqueue Font Awesome. */ function tu_load_font_awesome() { wp_enqueue_style( 'font-awesome', '//use.fontawesome.com/releases/v5.3.1/css/all.css', array(), '5.3.1' ); }
October 25, 2018 at 5:44 pm #710646AdamI did, but it is still not working.
October 25, 2018 at 6:28 pm #710661TomLead DeveloperLead DeveloperI’m still seeing Font Awesome 4 loading. It could be a plugin you’re using which is adding it.
Try adjusting Davids code to this:
add_action( 'wp_enqueue_scripts', 'tu_load_font_awesome' ); /** * Enqueue Font Awesome. */ function tu_load_font_awesome() { wp_enqueue_style( 'font-awesome-5', '//use.fontawesome.com/releases/v5.3.1/css/all.css', array(), '5.3.1' ); }
Not ideal, as it will load both versions of Font Awesome, but it will tell us if that’s the problem or not.
If it is, the next step will be to figure out which plugin is adding Font Awesome 4. You can do this by deactivating your plugins one by one with the original code David gave you until the icon works.
October 25, 2018 at 8:52 pm #710696AdamHi Tom,
So it looks like it fixed when I deactivated the beaver builder page builder plug in. So that is unfortunate, as I am wanting to use that plug in.
Any ideas or do you think I should ask beaver builder for support? It’s kind of a weird situation because the icons are not showing up on the generate press menu.
Thank you,
October 25, 2018 at 9:39 pm #710703TomLead DeveloperLead DeveloperI believe Beaver Builder has an option to use Font Awesome 5 instead of 4? It should be in their settings somewhere.
-
AuthorPosts
- You must be logged in to reply to this topic.