WordPress.org

Support

Support » Plugins and Hacks » [Plugin: AddToAny: Share/Bookmark/Email Buttons] Will not use page URL

[Plugin: AddToAny: Share/Bookmark/Email Buttons] Will not use page URL

  • Hi,

    the share URL is always and only the first post on any page or category listing, it will not use the page or category URL.

    There is a variable in add-to-any.php that I can find no other reference to or where this variable is set = $use_currentpage

    I have changed the following in add-to-any.php :

    // If not a feed
    if( ! $is_feed ) {
    if ($use_currentpage) {
    $_addtoany_targets[] = “\n{title:document.title,”
    . “url:location.href}”;
    } else {

    To:

    $is_front_page = is_front_page();
    $is_category = is_category();

    // If not a feed
    if( ! $is_feed ) {
    if ($is_front_page || $is_category) {
    $_addtoany_targets[] = “\n{title:document.title,”
    . “url:location.href}”;
    } else {

    This seem to work of for now.

    Gary.

    http://wordpress.org/extend/plugins/add-to-any/

  • The topic ‘[Plugin: AddToAny: Share/Bookmark/Email Buttons] Will not use page URL’ is closed to new replies.