• Resolved pao2

    (@pao2)


    Pretty much what the title says. Should not have included the author page URL when it’s noindexed.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Prabhat

    (@prabhatrai)

    Hi @pao2,

    Thanks for reaching out, and I apologize for the issue that you’re facing.

    It’s important to note that Author Archives and Author Name are two completely different things and don’t depend on each other. Author archives are usually noindexed since they have thin content and thus, they aren’t helpful from an SEO perspective.

    On the other hand, author name (and URL) is a recommended property by Google for the Article schema, and thus we add it. You can take a look at this documentation from Google for a quick reference –

    https://developers.google.com/search/docs/appearance/structured-data/article#article-types

    However, another thing to note here is that we don’t specifically use the username in the article schema, instead we use the value from the Display name publicly as field in the edit user settings. Screenshot –

    https://a.supportally.com/i/6f37Br

    If you’ve set the Display name publicly as field same as your username, then the same value would appear in the schema. In this case, you can simply update the above field to automatically update the schema.

    However, if you want to remove the author from the schema entirely, please share the URL of a post on your website and I’d be happy to share a filter that you can use to achieve this.

    Again, I want to assure you that we add the author’s name in the schema only because it’s a recommended property by Google which provides more context into the content.

    Please feel free to let me know if you have any questions.

    I’m really looking forward to helping you.

    Thanks!

    Plugin Support Prabhat

    (@prabhatrai)

    Hi @pao2,

    We haven’t heard back from you in a couple of days. I’m going to go ahead and close this thread for now. But if you’d like us to assist, please feel welcome to continue the conversation.

    Thanks!

    Thread Starter pao2

    (@pao2)

    Please share the filter here for future reference, i’m quite adept with codes. I just want to modify not remove the author’s URL as it contains username and is irrelevant when the author page is noindexed or blocked anyway. Thank you.

    Plugin Author arnaudbroes

    (@arnaudbroes)

    Here’s an example code snippet –

    add_filter( 'aioseo_schema_output', 'aioseo_filter_schema_output' );

    function aioseo_filter_schema_output( $graphs ) {
    if ( is_singular( 'post' ) ) {
    foreach ( $graphs as $index => $graph ) {
    if ( 'Article' === $graph['@type'] ) {
    unset( $graphs[ $index ]['author'] );
    }

    if ( 'Person' === $graph['@type'] ) {
    unset( $graphs[ $index ] );
    }
    }
    }
    return $graphs;
    }
Viewing 4 replies - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.