WordPress.org

Forums

WordPress Stats - Error from last API Key attempt: parse error. not well formed (9 posts)

  1. mastixmc
    Member
    Posted 6 years ago #

    I've tried to find a solution in the web, but unfortunately I wasn't able to find a solution... :(

    I've installed the WP Stats plugin... I also have an API KEY (Akismet is working fine), but when I enter my API key into the WP Stats plugin to activate it, it doesn't work and gives me the following error message:

    Error from last API Key attempt:

    parse error. not well formed

    The API key is definitely correct... Akismet is working fine with this key.

    I'm using the following versions:

    WP: 2.8.2
    WPSTATS: 1.5

    I've followed all the installation steps and so on... but it does NOT work... :(

    Do you guys have any idea what the problem might be?

    Thank you very much in advance,

    regards,

    Sascha

  2. oreixa
    Member
    Posted 6 years ago #

    I have exactly the same issue.

  3. oreixa
    Member
    Posted 6 years ago #

    Solved. Andy Skelton will release a new version, meanwhile you can edit the source of the plugin, replacing the line:

    'description' => get_option('blogdescription'),

    with:

    'description' => utf8_encode(get_option('blogdescription')),

  4. mastixmc
    Member
    Posted 5 years ago #

    Unfortunately that does not work for me. I've tried the solution you've proposed and then also replaced almost every line deliver UTF8-encoded values... no chance. Now I really need to debug that. :(

  5. mastixmc
    Member
    Posted 5 years ago #

    Ok, I've debugged it a little - no chance. The error code returned is 32700 - not well-formed. :(

    I had a look at all array values... Didn't see a problem. I've also put an "A" into all fields... still the same issue. Andy should definitely have a look into this thread.

    mastix

  6. Illegitima
    Member
    Posted 5 years ago #

    Here I keep having the same problem.

    Error from last API Key attempt:

    parse error. not well formed

    Any idea about how to fix it?

  7. darklocke
    Member
    Posted 5 years ago #

    Same problem here, had it for 9 months, no one seems to know the answer.

  8. rubhi
    Member
    Posted 5 years ago #

    same issue.

    ANY BODY READING THIS ISSUE OR NOT

  9. eddieparker
    Member
    Posted 5 years ago #

    Just thought I'd chime in. The problem for me was similar to what oreixa described.

    Basically anywhere in the function stats_get_blog, the array will have a bunch of get_option() calls. Wrap those in utf_encode() and it can solve the parse error.

    I'm guessing that the plugin is sending an XML request in UTF8 but if your blog isn't set to UTF8 (like mine wasn't - I'm ISO8559-1, I believe), then it would end up as crap characters and would essentially look like a parse error.

    Doing this will force everything to be UTF8 and everything should just work.

Topic Closed

This topic has been closed to new replies.

About this Topic