Hello,
Please take a look at this post:
https://kriesi.at/support/topic/implement-relpublisher-instead-of-relauthor-in-the-g-social-icon/
I want the same for the website http://www.onsnh.nl and I want to change the child-theme and not the main document.
But just for testing purposed I changed the function-enfold.php file but nothing happend:
http://nl.tinypic.com/r/2hghklj/8
Can you tell me how to alter the function-enfold.php and how to add this to the child theme?
Isn’t it something that can be changed on next update because it looks like more people have this problem?!
Greets Jeen
Hey Jeen!
Try copying the modified avia_google_author_image
to your child theme functions.php:
function avia_google_author_image()
{
$icons = avia_get_option('social_icons');
if(is_array($icons) && !empty($icons))
{
foreach($icons as $icon) if($icon['social_icon'] == 'gplus') $url = $icon['social_icon_link'];
}
if(!empty($url))
{
//add author url as described here: http://yoast.com/push-rel-author-head/
echo '<link rel="author" href="'.$url.'"/>';
}
}
Regards,
Josue
Hello Josue,
Thanks for the snippet. I’ve altered the functions.php but the link hasn’t got the ‘author’ tag in it.
Please take a look at the print screen I’ve send with my previous post or check the code on http://www.onsnh.nl
Greets Jeen
Hey!
You can try this on functions.php:
/**
* g+ author
*/
add_filter('wp_footer', 'avf_g_plus', 10);
function avf_g_plus() { ?>
<script>
(function($){
$(window).load(function(){
$('.social_bookmarks_gplus a').attr('rel', 'author');
});
})(jQuery);
</script>
<?php
}
Regards,
Ismael
Thanks Ismael! It works!!
Greets Jeen