• I’ve entered my Google+ profile into the “Social links” section of Customizr, but it doesn’t include the rel=”publisher” attribute that would better tie Google+ and my site.

    From Google+:
    “By adding a short line of code to XXXX, you can make your Google+ page eligible to show up on the right-hand side of the Google search page for relevant queries and make your Google+ page more discoverable.”

    Please can you add support for this?

Viewing 4 replies - 1 through 4 (of 4 total)
  • I think you can use a seo plug-in to add that rel, or use this snippet 2-2 alternative method and replacing that
    <link href='https://fonts.googleapis.com/css?family=Raleway' rel='stylesheet' type='text/css'>
    with

    <link rel="publisher" href="YOUR_ACCOUNT_LINK_HERE" />

    Thread Starter sunryzer

    (@sunryzer)

    I have the rel=”publisher” in my header from the Yoast SEO plugin but that’s not enough to verify according to Google+ – it requires it to be a part of the link.

    I could add an “invisible” Google+ link with it in but I would rather not as that affects screen readers.

    Oh I see. Sorry I failed to get.
    I presume you can have more than one rel=”publisher” .. for page right?
    I mean, if you use more than one social block, e.g. in header and in the sidebar, of course you have more than one google+ link. Can you have this rel attribute for both?

    @sunryzer
    add this to your child theme functions.php to add the rel attribute to all your google+ social links:

    add_filter('tc_additional_social_attributes', 'add_google_attr', 10, 2 );
    function add_google_attr($attr, $key){
        if ( $key != 'tc_google' )
            return $attr;
    
        $rel_pub_attr = 'rel="publisher"';
        return $attr . $rel_pub_attr;
    }

    Hope this helps

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Google rel attibute’ is closed to new replies.