Tagged: enfold, functions.php, social icons
-
AuthorPosts
-
May 31, 2022 at 3:52 pm #1353605
Hey,
I added my own social icon to my website with the tutorial from the forum:
https://kriesi.at/documentation/enfold/social-share-buttons/#toggle-id-1And now, when hovering on the icon, the following alt-text displays “Icon_name”. Does anyone have an idea how to change the alt-text?
(I used the Child Theme from Enfold)- This topic was modified 2 years, 6 months ago by Julian Post.
May 31, 2022 at 4:26 pm #1353607This “icon_name” are only placeholder texts.
you had to change it to your needs f.e.
// Register new icon as a theme icon function avia_add_tiktok_icon($icons) { $icons['tiktok'] = array( 'font' =>'entypo-fontello', 'icon' => 'ue8fa' , 'display_name' => 'TikTok'); return $icons; } add_filter('avf_default_icons','avia_add_tiktok_icon', 10, 1); // Add new icon as an option for social icons function avia_add_tiktok_social_icon($icons) { $icons['TikTok'] = 'tiktok'; return $icons; } add_filter('avf_social_icons_options','avia_add_tiktok_social_icon', 10, 1);
that display_name was new to me too. It is only necessary if you need a special writing for the icon (also for hovering). Here it is the second big T in the icon name ( like WhatsApp etc. )
May 31, 2022 at 4:46 pm #1353609in the second snippet the :
$icons['TikTok'] = 'tiktok';
on the left determines the way it is shown in the dropdown-list on enfold – social profiles – Your social profiles ( you can have here:$icons['Mein TikTok Icon'] = 'tiktok';
)
the “tiktok” is used to create the corresponding classes – so here now : social_bookmarks_tiktok and av-social-link-tiktok
and the title and aria-label – with a big letter at the beginning.
If you like to change that – the display_name will be set.June 1, 2022 at 4:34 am #1353654Hi Julian,
Please follow Guenni007’s solution.
@Guenni007, thanks for always helping out :)Best regards,
NikkoJune 2, 2022 at 11:11 am #1353898Thank you @guenni007, it worked!
June 2, 2022 at 2:19 pm #1353920 -
AuthorPosts
- You must be logged in to reply to this topic.