- This topic has 4 replies, 2 voices, and was last updated 9 years ago by Tom.
-
AuthorPosts
-
April 14, 2015 at 3:35 pm #98572Webmaster
Any ideas? How would I add the below link to my WordPress Primary Menu?
<a href="skype:profile_name?userinfo">Link to my profile</a>
After I save, the link gets removed and I have an icon button (but no link).
—
http://stackoverflow.com/questions/16177332/create-application-link-to-skype-profile?rq=1
I thought I found a help function but when I copy / paste that chunk into the functions.php I get zilch
April 14, 2015 at 10:59 pm #98632TomLead DeveloperLead DeveloperHmm, I looked into this a bit and the only function I found was the one you linked to.
From looking at it, it definitely looks like it should work.
What happens to the link when you add it while that function is active in your child theme? Anything at all?
April 14, 2015 at 11:04 pm #98661WebmasterIt just doesn’t work when I copy / paste that snippet into my child function.php
Hmm…I’ll just ask my brother, I know this doesn’t really fall under theme support but more of a WordPress thing. Once I find the answer, I’ll post the reply.
I just tried to copy / paste the plugin from WordPress.org repo and still no results.
https://wordpress.org/plugins/vihv-skype-and-callto-links/
This was the function:
function vihv_skype_callto_links($protocols) { if(!empty($protocols)) { $protocols[] = 'skype'; $protocols[] = 'callto'; $protocols[] = 'tel'; } return $protocols; } add_filter('kses_allowed_protocols', 'vihv_skype_callto_links');
It appears as if the WordPress menu manager module just refuses to show love towards Skype. I’m going to dig deeper into this tomorrow. Enjoy your evening.
April 16, 2015 at 2:45 pm #99256WebmasterHere is a patch, editing generatepress/inc/navigation.php
On line #98 in the item wrap I added
<li><a href="skype:user_profile?userinfo"><i class="fa fa-skype"></i></a></li>
before the %3 parameter. A cleaner alternative is to create a custom nav walker. A negative is after each theme update I’ll have to update this file.If you have any suggestions, just let me know.
April 16, 2015 at 11:00 pm #99360TomLead DeveloperLead DeveloperInstead of editing the core file, I suggest doing something like this: http://wordpress.stackexchange.com/questions/2143/customizing-only-a-specific-menu-using-the-wp-nav-menu-items-hook
-
AuthorPosts
- You must be logged in to reply to this topic.