• Resolved nagely

    (@nagely)


    Hello,

    I am using addtoany share buttons on the top of the page attached.

    (the buttons where added directly through PHP, not by using a shortcode).

    When clicking on the facebook share button the first time, the href is loaded on the button with the wrong URL (it is actually a URL that belongs to another share button on the bottom of the page).
    Only when clicking on the button a second time does the correct URL from the data-a2a-url load on the button.

    I checked the meta tags on the page (og:url etc.) and they seem to be correct.

    Please help,

    Yaron

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author micropat

    (@micropat)

    Hi Yaron,

    To fix that, just change the a.a2a_button_* elements to be children of .a2a_kit (instead of nested in lis).

    That kind of semantic nesting (like ul.a2a_kit > li > a.a2a_button_*) can cause issues when there are multiple sharing instances on a page, so for now it’s best to stick with .a2a_kit > a.a2a_button_* as documented for AddToAny core.

    Eventually one level of nesting will be supported for list elements, etc. 🙂

Viewing 1 replies (of 1 total)

The topic ‘Facebook shares the wrong link’ is closed to new replies.