-
AuthorPosts
-
June 8, 2015 at 8:23 am #455768
How can I add my own Social Icons in the Social Profiles area. There are limited choices so I’d like to be able to add my own icon so I can link to a IMDB profile.
June 8, 2015 at 10:17 am #455881Hi!
1. Import them as a webfont, they should be available as a webfont here.
2. Add this at the very end of your theme / child theme functions.php file:
function avia_add_custom_icon($icons) { $icons['imdb'] = array( 'font' =>'_IMPORTED_FONT_NAME_HERE_', 'icon' => '_ICON_CODE_HERE_'); return $icons; } add_filter('avf_default_icons','avia_add_custom_icon', 10, 1); function avia_add_custom_social_icon($icons) { $icons['imdb'] = 'imdb'; return $icons; } add_filter('avf_social_icons_options','avia_add_custom_social_icon', 10, 1);
Best regards,
JosueJune 20, 2015 at 6:51 am #462155I have tried several times and it is not working – what could the issue be?
June 20, 2015 at 10:00 am #462175Hi,
Can you please create us a WordPress administrator account? post it here as a private reply.
Regards,
JosueJune 21, 2015 at 9:30 pm #462397This reply has been marked as private.June 22, 2015 at 2:33 pm #462798Hey!
I recommend adding it to a child theme functions.php file but if you need to add it to Enfold’s functions.php then you’ll need to move it up around line 10. I already did it for you.
Next you need to change this line.
$icons['imdb'] = array( 'font' =>'fontello', 'icon' => 'imdb');
To something like this.
$icons['imdb'] = array( 'font' =>'fontello', 'icon' => 'ue803');
If your not sure which “ue803” to use then extract the zip file of the font you downloaded and look inside the /fonts/ folder. If you open up the .svg file in a text editor you’ll see a line like this.
<glyph glyph-name="crown" unicode="" d="m419 822c-39 0-71-32-71-72 0-40 32-72 71-72 39 0 74 32 74 72 0 40-35 72-74 72z m-48-222c-40-119-101-152-101-152s-52 146-109 232c-23-52-47-86-96-100-1-44 51-208 55-290l601 0c2 79 55 256 55 288-38 16-85 51-96 102-63-86-109-232-109-232s-61 33-101 152c-27-13-77-13-99 0z m-297 222c-40 0-74-32-74-72 0-40 34-72 74-72 39 0 70 32 70 72 0 40-31 72-70 72z m47-603l0-119 600 0c0 43 0 81 0 119z m644 603c-40 0-72-32-72-72 0-40 32-72 72-72 40 0 72 32 72 72 0 40-32 72-72 72z" horiz-adv-x="837" />
You can grab the number to use there,
unicode=""
.EDIT: You can also change which code to use on the fontello.com site. Click on the “Customize Codes” tab after selecting the icons you want.
Best regards,
Elliott- This reply was modified 9 years, 6 months ago by Elliott.
June 22, 2015 at 3:07 pm #462817Check it now, i ended up using a plugin to store the custom code (Plugins > Edit Functions).
Cheers!
Josue -
AuthorPosts
- You must be logged in to reply to this topic.