Viewing 13 replies - 1 through 13 (of 13 total)
  • I have exactly the same problem. It only appears on page 404

    1.0.2 of the plugin on WP 3.6.1

    Hey guys, sorry you’re having problems. Let’s try to figure out what’s causing the problems.

    @joelgoodman – what type of theme are you using? On your 404 page, there’s a JS error that I think is causing the Share layer not to show up.

    @jghes – do you have a link to your site we could look at? And same question as above, what theme are you using?

    I deactivated SEO by Yoast. Now it worked in Opera, Chrome but not in IE and Firefox.

    My page: https://vernepleierportalen.no/

    Theme: https://www.woothemes.com/products/canvas/

    Thread Starter Joel G Goodman

    (@asilentthing)

    I’m a professional theme developer. Everything I do is hand-coded to the current WP specifications for theme development using modern WordPress functions and techniques. That said, this theme was built from scratch, by me.

    If you take a look, that js error that console is throwing is apart of the addThis script…

    </script><script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=de5052ebd24c66a8d2fe157b83e70a75"></script><script type="text/javascript">addthis.layers({
    theme : 'dark',
    share : {
        'position' : 'left',
        'services' : 'facebook,twitter,pinterest',
        //'numPreferredServices' : 5,
        'postShareTitle' : 'Thanks for sharing!',
        'postShareFollowMsg' : 'Follow us',
        'postShareRecommendedMsg' : 'Recommended for you'
    }
    mobile : {
        'buttonBarPosition' : 'bottom',
        'buttonBarTheme' : 'dark'
    }
    }
      );</script>

    The error is caused at mobile: { according to the console readout with an error of [Error] SyntaxError: Expected token '}' (404, line 108)

    And it doesn’t even load the AddThis script and markup on other pages.

    Which I’m guessing is because you need a , after the share{} object…

    Thread Starter Joel G Goodman

    (@asilentthing)

    Well, so I figured that part of the error out — Even if I switch back to WYSIWYG and save changes, if there was custom code left in the Advanced field, it will still load the “Advanced” custom code (that’s bad practice).

    So now, you’ll see it shows up on 404, but without the settings I’ve applied in the WYSIWYG settings (should be the dark theme, not transparent).

    @joelgoodman: Unfortunately I cannot reproduce the issue in the themes I test with (mostly popular free themes). Do you have any additional steps which might lead to the issue?

    Also, there was another issue in saving the WYSIWYG settings and we have released a fixed version as of now(1.0.3). Can you verify your issue exists in this version?

    Thread Starter Joel G Goodman

    (@asilentthing)

    Well… the update throws a few errors when debug is on… I guess I have some digging to do in the code.

    Notice: Use of undefined constant ADDTHIS_SMART_LAYER_PRODUCT_CODE - assumed 'ADDTHIS_SMART_LAYER_PRODUCT_CODE' in /wp-content/plugins/addthis-smart-layers/addthis-smart_layers.php on line 12
    
    Notice: Use of undefined constant ADDTHIS_SMART_LAYER_AT_VERSION - assumed 'ADDTHIS_SMART_LAYER_AT_VERSION' in /wp-content/plugins/addthis-smart-layers/addthis-smart_layers.php on line 13
    Thread Starter Joel G Goodman

    (@asilentthing)

    I also get this notice in the WP Admin on activation:
    The plugin generated 530 characters of unexpected output during activation. If you notice “headers already sent” messages, problems with syndication feeds or other issues, try deactivating or removing this plugin.

    @joelgoodman: The notice is due to the Notice getting printed. This shouldn’t be the reason for the original issue mentioned. But thanks for pointing it out, it is fixed now and will be available from next release.
    Does the original issue still exist?

    Thread Starter Joel G Goodman

    (@asilentthing)

    Original issues exists, but since this is for a client, I’ve just gone and done it through wp_enqueue_scripts manually. And that’s working fine. Still not sure what the issue is with the plugin.

    @joelgoodman: I checked your site in Chrome and FF and the Share layer is showing up in home page and other pages. I assume it is now done through wp_enqueue_scripts. If you can provide an access to your dashboard, may be in a dev site, I can check and help you out. You can add srijith[AT]addthis.com as the user.

    Thread Starter Joel G Goodman

    (@asilentthing)

    Won’t be able to today, too busy. Looked like the plugin wasn’t properly printing through wp_footer(); originally. Not sure if something was hanging it up, or what, but I ran both the WP theme checker plugin and made sure debug wasn’t throwing any errors and all came up clean for my theme.

    Manually writing the JSON object for the parameters and loading the addthis script via wp_enqueue scripts has worked for me, for now.

    It would be nice in the WYSIWYG to be able to choose some of the share buttons included, so I probably would have needed to use the Advanced panel to get at those anyway. At that point, I might as well just load it directly through my theme functions so I can control where and when it enqueues.

    I’m having the same problem- the plug in is only showing up on the 404 page.

    I’m not a coder, is there an easy way to make the plug in work on the Theme Blvd- Stealth theme on my site: https://kristyoustalet.com

    Thanks!

Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘Shows on 404 but no other pages’ is closed to new replies.