Support » Plugins and Hacks » [Resolved] [Plugin: AddThis] Parse error / syntax error

[Resolved] [Plugin: AddThis] Parse error / syntax error

  • Hi,

    Whe I try to activate this plugin in WordPress 2.6.5, I get the following error:

    Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or ‘}’ in /wp-content/plugins/addthis/addthis_social_widget.php on line 35

    Also, does it have a feature to allow you to disable it on certain pages yet?

Viewing 15 replies - 1 through 15 (of 25 total)
  • This also happened to me after updating to the latest version (1.5 I believe). I’ve disabled this plugin until a fix is available. Can anyone help?

    Oh yes, I forgot to mention that – I’m talking about version 1.5 (earlier versions don’t produce this error).

    I have the same error…………. ((

    I get this error using version 1.5 of the plugin and WordPress 2.7/

    Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or ‘}’ in /homepages/44/d92908046/htdocs/cxoblog/wp-content/plugins/addthis/addthis_social_widget.php on line 35

    Hey, so sorry guys! This is Matt from AddThis. We wrote this for PHP 5 only, not PHP 4. However, it seems like despite the official end-of-lifing last year, it’s still one of the most dominant flavors, so we’re going to make a backport soon. Sorry for the trouble!



    May we have a link to the older version to use until the backport is available?

    Our older plugin also only supported PHP 5, unfortunately. But I ported it over the holiday and we’ll be formally testing it in PHP4 this week.


    Okay, the PHP4 version has been added to the plugin zip in its own special /php4 directory. It seemed okay in our local testing — can one of you PHP 4 users try it out and let me know?


    It activated for me in 2.6.2. Working fine. Thank you.

    I click the button and get a page full of icons with this headline: “Bookmark & Share”
    When I click an icon (I’ve tried several), I get a page like this one:
    http://www.addthis.com/ask, with this text:

    “Sorry, the page you were trying to get to, ask, doesn’t exist.
    Since you came from one of our own pages, we must have a bad link. Yikes! We’ll correct this ASAP.”

    This behavior occurred with the Addit WordPress plugin from the php4 subdirectory, as downloaded a few minutes ago. (The default version results in the “Parse error: syntax error, unexpected T_STRING…” mess.)

    I’ve tried this with two WordPress installations, versions 2.7 and 2.6.3.

    Not good.

    Problem identified: I suggest that you change the “Sorry…” message to suggest that Javascript must be enabled (for Addthis.com; the Noscript Firefox plugin can block it).

    Oh, interesting. Unrelated to the plugin itself, but we’ll look into changing that — the bookmark page ought to support JavaScriptless environments.

    I’ll also note in the readme that JavaScript is required.

    Yep, the PHP4 version does work!

    However, in common with the old drop down version of the plug-in, it has a bizarre problem – the second post on each page disappears!

    This problem goes away if I dsiable the drop-down menu, but I’d really like to use the drop-down menu if possible.

    I am using WordPress 2.6.5, with the Tarski 2.3 theme.

    Hm, does the problem occur if you use the default theme?

    Sorry, I already reverted back to 1.0 before trying that!

    What I did find though is that if I reload the page in my browser, the post can sometimes reappear. Or sometimes more of them can disappear!

    I’ve also found that it doesn’t happen in all browsers – I use Mac OS 9, so my browsers are all pretty old. Mozilla 1.3 (the latest version for my OS) has the problem, but Internet Explorer doesn’t.

    Perhaps it is just some JavaScript issue or something with old browsers – I would be intrigued to learn if anyone else has experienced the same problem. A very strange one to be sure!

Viewing 15 replies - 1 through 15 (of 25 total)
  • The topic ‘[Resolved] [Plugin: AddThis] Parse error / syntax error’ is closed to new replies.