• timyates

    (@timyates)


    Hi,

    I’m trying to organise a custom menu for the social profiles on my site. It all works fine except that the email icon disappears when I use a custom menu. When I add an emailto: link to the menu itself the proper icon doesn’t display either (I get a default icon). Is there any way to get the proper mail icon?

    Many thanks

Viewing 4 replies - 1 through 4 (of 4 total)
  • Balint Toth

    (@tothbalint)

    Hello!

    Could You please share a link to Your site so we could take a look, and probably provide a solution, specifically for Your site?

    Cheers,
    Balint

    Thread Starter timyates

    (@timyates)

    Hi Balint,

    Sure – that’d be amazing!

    The address is:

    https://109.73.233.145/~timyates/hackoustic.org/

    The top right icon should be the mail symbol – the other default icon is for google groups, although I assume there’s nothing that can be done about that!

    It may be that I’ve set it up wrongly of course ??

    Tim

    Balint Toth

    (@tothbalint)

    Hello!

    I have made a little bit of digging (okay, to be honest, a bit more than that). First of all, I think the documentation article is a little bit misleading, or at least for me it is, because in my understanding, You should type into the Link Text field the name of the site (facebook, google plus, etc) from the unordered list.

    However, upon checking the PHP code, it turns out, the script is checking the URL to match it with the proper social profile links. Here is what it is searching for:

    $supported_icons = apply_filters( 'make_supported_social_icons', array(
    		'angel.co'           => 'fa-angellist',
    		'app.net'            => 'fa-adn',
    		'behance.net'        => 'fa-behance',
    		'bitbucket.org'      => 'fa-bitbucket',
    		'codepen.io'         => 'fa-codepen',
    		'delicious.com'      => 'fa-delicious',
    		'deviantart.com'     => 'fa-deviantart',
    		'digg.com'           => 'fa-digg',
    		'dribbble.com'       => 'fa-dribbble',
    		'facebook.com'       => 'fa-facebook',
    		'flickr.com'         => 'fa-flickr',
    		'foursquare.com'     => 'fa-foursquare',
    		'github.com'         => 'fa-github',
    		'gittip.com'         => 'fa-gittip',
    		'plus.google.com'    => 'fa-google-plus-square',
    		'instagram.com'      => 'fa-instagram',
    		'jsfiddle.net'       => 'fa-jsfiddle',
    		'last.fm'            => 'fa-lastfm',
    		'linkedin.com'       => 'fa-linkedin',
    		'pinterest.com'      => 'fa-pinterest',
    		'qzone.qq.com'       => 'fa-qq',
    		'reddit.com'         => 'fa-reddit',
    		'renren.com'         => 'fa-renren',
    		'slideshare.net'     => 'fa-slideshare',
    		'soundcloud.com'     => 'fa-soundcloud',
    		'spotify.com'        => 'fa-spotify',
    		'stackexchange.com'  => 'fa-stack-exchange',
    		'stackoverflow.com'  => 'fa-stack-overflow',
    		'steamcommunity.com' => 'fa-steam',
    		'stumbleupon.com'    => 'fa-stumbleupon',
    		't.qq.com'           => 'fa-tencent-weibo',
    		'trello.com'         => 'fa-trello',
    		'tumblr.com'         => 'fa-tumblr',
    		'twitch.tv'          => 'fa-twitch',
    		'twitter.com'        => 'fa-twitter',
    		'vimeo.com'          => 'fa-vimeo-square',
    		'vine.co'            => 'fa-vine',
    		'vk.com'             => 'fa-vk',
    		'weibo.com'          => 'fa-weibo',
    		'weixin.qq.com'      => 'fa-weixin',
    		'wordpress.com'      => 'fa-wordpress',
    		'xing.com'           => 'fa-xing',
    		'yahoo.com'          => 'fa-yahoo',
    		'yelp.com'           => 'fa-yelp',
    		'youtube.com'        => 'fa-youtube',

    which is in the file wp-content/themes/make/inc/template-tags.php from line number 354.

    The reason Your google plus link is not recognised, because it is not the ‘usual’ plus.google.com link.

    I have managed to add in the email icon by a little bit of hacking, but I have to state, THIS IS NOT THE PROPER WAY of doing this. I have edited the mentioned template-tags.php file directly, and added a new row, which adds an email icon whenever there is a mailto: in the link, and it looks like this (only the last couple of rows):

    'yahoo.com'          => 'fa-yahoo',
    		'yelp.com'           => 'fa-yelp',
    		'youtube.com'        => 'fa-youtube',
    		'mailto:'	     => 'fa-envelope-o'
    	) );

    Please note, that this is not the proper way, because this way if you update Your theme, this change will be overwritten.
    The proper way to do this is by adding a child theme and doing the modifications there, but that is a bit longer process. It is late night right now where I live, please give me a day and I will provide You with the exact steps needed to solve this properly.

    Cheers,
    Balint

    Thread Starter timyates

    (@timyates)

    Hi Balint,

    That’s absolutely amazing – I made the changes and they worked perfectly. I’ve had a look at using a child theme, but I’m not sure about the details and don’t want to get it wrong so I’ll wait for your instructions before trying it.

    Thanks so much for your help!

    Tim

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Email icon for custom menu’ is closed to new replies.