WordPress.org

Ready to get started?Download WordPress

Forums

Fancier Author Box by ThematoSoup
Google+ Authorship doubled (7 posts)

  1. Mangusta76
    Member
    Posted 4 months ago #

    Hi!

    I updated the plugin to the last version and I have a problem with Google authorship.
    I already have rel=author on my page, so the one from FAB is a duplicate. Google testing tools tells me that the second one is not considered, but I wonder if there is a way to fix it.

    Thanks!

    https://wordpress.org/plugins/fancier-author-box/

  2. Dragan Nikolic
    Member
    Plugin Author

    Posted 4 months ago #

    Not possible without editing the code.

  3. Mangusta76
    Member
    Posted 4 months ago #

    How can I edit the code?

    Thanks!

  4. pupilla
    Member
    Posted 4 months ago #

    Dear Dragan,

    can you make the "rel=author" optional in your next update please?

    My problem: I promote my Google+-Page with my Fancier Author Box but unfortunately the pages are not allowed for Google authorship (only rel=publisher - I suppose you know that). Like Megusta76 I use "rel=author" somewhere else in my template.

    @Megusta76

    To remove the "rel=author" you have to open ts-fab-construct-tabs.php file from includes directory in the plugin folder. Take a look in the lines after 49 - there is "rel=author" in two lines and just remove them. Make sure you don't remove anything else because it breaks the plugin.

    $ts_fab_googleplus_url = get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . ' REMOVES HERE ';

    and here

    $ts_fab_googleplus_url = 'http://plus.google.com/' . get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . ' REMOVED HERE ';

  5. Dragan Nikolic
    Member
    Plugin Author

    Posted 4 months ago #

    Hi,

    We'll definitely consider it.

    Thanks and regards

  6. Mangusta76
    Member
    Posted 4 months ago #

    Thank you Pupilla! If I understood well the lines:

    if ( get_user_meta( $author->ID, 'ts_fab_googleplus', true ) ) {
    					if ( ts_fab_is_url( get_user_meta( $author->ID, 'ts_fab_googleplus', true ) ) ) {
    						$ts_fab_googleplus_url = get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . '?rel=author';
    					} else {
    						$ts_fab_googleplus_url = 'http://plus.google.com/' . get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . '?rel=author';
    					}

    Become:

    if ( get_user_meta( $author->ID, 'ts_fab_googleplus', true ) ) {
    					if ( ts_fab_is_url( get_user_meta( $author->ID, 'ts_fab_googleplus', true ) ) ) {
    						$ts_fab_googleplus_url = get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . ;
    					} else {
    						$ts_fab_googleplus_url = 'http://plus.google.com/' . get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . ;
    					}

    [Moderator Note: Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum's parser.]

    correct?

    Thanks again!

  7. pupilla
    Member
    Posted 4 months ago #

    Hi,

    you have to leave the ' ':

    if ( get_user_meta( $author->ID, 'ts_fab_googleplus', true ) ) {
    if ( ts_fab_is_url( get_user_meta( $author->ID, 'ts_fab_googleplus', true ) ) ) {
    $ts_fab_googleplus_url = get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . '' ;
    } else {
    $ts_fab_googleplus_url = 'http://plus.google.com/' . get_user_meta( $author->ID, 'ts_fab_googleplus', true ) . '';
    }

    [Moderator Note: Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum's parser.]

    I tried it without (then the dot has to be removed as well) but then I had some problems with the admin section. Maybe there is a possibility to make it "cleaner" but I didn't want to waste the time to find out and left it this way. No guarantee :))

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.