• Resolved ante1974

    (@ante1974)


    Hi there,

    I am using the following code:

    [authors_list style="2" columns="3" link_to="meta" link_to_meta_key="user_url" show_link="no" show_count="no" show_bio="no" name_starts_with="A" after_bio='<a class="authorProfile" href="{al:user_url}">View Profile</a>' orderby="display_name" order="ASC"]

    2 things:

    1 – How can I add a trailing slash to the anchor link? At the moment the lack of a trailing slash is causing 301 redirects.

    2 – I think there is something wrong with my link be it doesn’t take the class “authorProfile”

    I’m headed in the right direction but need a little help.

    Dev site is behind a login so I can’t provide access.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author WPKube

    (@wpkube)

    Hi @ante1974

    The {al:FIELD_NAME} simply outputs the a value of a user meta field, it doesn’t do any modifications to the value. The only fix is to correct the URLs that are set for that user field.

    Or if they’re all missing the slash you could just add it in the shortcode href="{al:user_url}/"

    As for the class, I tried the same shortcode you are using and the class is there. Can you send over the URL to the page where you have the authors list, seeing it might give me an idea as to what’s going on.

    Thread Starter ante1974

    (@ante1974)

    @wpkube Thanks for your advice. I checked my DB and found that only the user I was testing against had somehow omitted a trailing slash from the URL, so the issue is resolved. I corrected the URL as suggested.

    Many thanks,

    • This reply was modified 3 years, 1 month ago by ante1974. Reason: Forgot to mark as resolved
    Plugin Author WPKube

    (@wpkube)

    You’re welcome @ante1974

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Add a trailing slash to author URL’ is closed to new replies.