Forums

Parser error

  1. I'm using an iPad 2 and v. 3.9. When I tried to refresh the comments I got an NSXML parsererror domain error 111. I then deleted the app and reinstalled it. Now I can't find the WP icon anywhere on the iPad desktop. But when I open WP from the Store and try to login with the correct login data, I get the same error. I've double & triple checked that I'm using the correct login data.

    There is something corrupted somewhere. Anyone having a similar problem?

    Also, when I go into a post that has already been published or saved to draft there is no formatting. If I do editing in WP for ios and save it, all the formatting I'd added on my desktop disappears. Thus, I can't use WP ios for editing posts at all.

  2. A parse error can mean that your blog is sending some unexpected data to the app when only XML is expected. I took a quick look at your blog's XML-RPC endpoint but I didn't see anything obviously broken being returned, so I wonder if you'd try enabling the Extra Debug feature and sending us an log of the error occufring.
    http://dev.ios.wordpress.org/extra-debug/

    Regarding your question about formatting, the app currently has a simple plain-text editor. The team is working to include a visual editor in an upcoming release.

  3. I cannot even successfully login. When I enter the correct information I get the parsererror. It won't even log me in.

    In previous releases, the text retained the formatting of the original if I created it using the PC/browser version of WP. But somewhere along the way it lost the formatting & all the text is completely unformatted, making it impossible for me to edit an existing post I created using my PC.

    Thanks for the hint concerning the debug feature.

  4. I have the same error message
    here below are the logs :
    2014/02/07 13:22:55:804 <WordPressAppDelegate: 0x17e5a530> applicationWillEnterForeground:
    2014/02/07 13:22:55:950 <WordPressAppDelegate: 0x17e5a530> applicationDidBecomeActive:
    2014/02/07 13:23:03:085 <WordPressComApi: 0x17ea3bf0, baseURL: https://public-api.wordpress.com/rest/v1/, defaultHeaders: {
    "Accept-Language" = "fr;q=1, en;q=0.9, de;q=0.8, ja;q=0.7, nl;q=0.6, it;q=0.5";
    Authorization = "Bearer At66FZ^3TutyAoIAxukXNwHYOzqS8Ed4MNlDG6tW!BQj*4sA3ITXX4@gzLz0i8WL";
    "User-Agent" = "wp-iphone/3.9 (iPhone OS 7.0.4, iPad) Mobile";
    }, registeredOperationClasses: (
    WPJSONRequestOperation
    ), operationQueue: <NSOperationQueue: 0x17e0f1c0>{name = 'NSOperationQueue 0x17e0f1c0'}> reset
    2014/02/07 13:23:03:432 Error while retrieving WordPressComOAuthKeychainServiceName token: Error Domain=SFHFKeychainUtilsErrorDomain Code=-25300 "The operation couldn’t be completed. (SFHFKeychainUtilsErrorDomain error -25300.)"
    2014/02/07 13:23:03:741 Merging changes into main context
    2014/02/07 13:23:33:054 Error Domain=NSXMLParserErrorDomain Code=111 "The operation couldn’t be completed. (NSXMLParserErrorDomain error 111.)"
    2014/02/07 13:23:44:301 <WordPressAppDelegate: 0x17e5a530> applicationWillResignActive:
    2014/02/07 13:23:45:898 <WordPressAppDelegate: 0x17e5a530> applicationDidBecomeActive:
    2014/02/07 13:25:26:383 Error Domain=NSXMLParserErrorDomain Code=111 "The operation couldn’t be completed. (NSXMLParserErrorDomain error 111.)"
    2014/02/07 13:25:36:314 Error Domain=NSXMLParserErrorDomain Code=111 "The operation couldn’t be completed. (NSXMLParserErrorDomain error 111.)"
    2014/02/07 13:25:47:667 <WordPressAppDelegate: 0x17e5a530> applicationWillResignActive:
    2014/02/07 13:25:47:670 <WordPressAppDelegate: 0x17e5a530> applicationDidEnterBackground:
    2014/02/07 13:27:10:754 <WordPressAppDelegate: 0x17e5a530> applicationWillEnterForeground:
    2014/02/07 13:27:10:851 <WordPressAppDelegate: 0x17e5a530> applicationDidBecomeActive:

    when I try

    mywebsite/xmlrpc.php
    I get the message
    XML-RPC server accepts POST requests only.

  5. @didlerott When I visit http://ott.fr/wp/xmlrpc.php in a browser I see a lot of html and javascript being returned. The only thing you should ever see from this page when visiting it in a browser is the short message that "XML-RPC server accepts POST requests only" and the extra stuff is likely what's causing the parse error.

    Please try switching to a default theme and disabling plugins to see if the problem continues. If the problem goes away you can switch the theme back and enable plugins one at a time until you find the one causing a conflict.

  6. please have a look on

    veronicook.ott.fr/xmlrpc.php

    I have de-activated all plugins and I use the standard theme
    and I get
    XML-RPC server accepts POST requests only.

    and impossible to access it with the apps on IPad

  7. Still waiting for a reply to my post. Can't login at all. Any suggestion?

    Working fine on Android. just not ipad.

  8. Trying to work on my iPad Air iOS 7.0.4 with the WordPress.app 3.9. Since a few days I get the parser error 111. De-install and re-install didn't help.

    Blog 'digitalaniv.com' is hosted on wordpress.com with standartd plugins only.

  9. I've tried all different formats for my blog URL. Can you tell me what the accepted format is for the login?

    Also, I have a self-hosted blog.

  10. @richards1052 Please try a default theme and deactivating plugins to see if the problem is caused by a conflict there.

    Also, you can enter "www.richardsilverstein.com" on the sign in screen for your blog URL.

  11. Too complicated. I'm just going to stop using the app. Thumbs down on it, in my opinion.

  12. With the IOS app , it doen't work - even with the standard theme and without plugins
    with the Android App, it is running well.

    is it possible to have more information about the causes of the generation of this message by the lines of code of the IOS app ?

  13. @didierott Sure.
    To get a list of posts, the iOS app makes a call to your blog's XML-RPC endpoint: xmlrpc.php. The XML-RPC method being requested is metaWeblog.getRecentPosts
    http://codex.wordpress.org/XML-RPC_MetaWeblog_API#metaWeblog.getRecentPosts
    What should happen when a blog receives this request, is it should return well formatted XML containing a list of posts from your blog.

    A few people who have reported the parse error have been gracious enough to provide us with credentials for testing on their blog. What we're seeing is the response from the server is being truncated. The last few characters are being omitted from the response from the server. This makes the response invalid XML, which is why you see a parse error in the app.

    Why this suddenly started happening for some users remains a mystery. I've wondered if the cause could be due to a bug introduced in a plugin update (remember WordPress has background updates since 3.7) which is why I've asked a few folks to try disabling plugins to see if the parse error goes away.

    While the root cause of the problem appears to be something server-side, we're looking for ways we might work around it in an update to the app.

    Hope this helps clear things up, at least as far as our understanding of what's happening. Its a frustrating bug for all of us!

  14. Hi eric,
    I have some matter that could be useful to understand .. : http://ott.fr/xmlrpc/comments.pdf

    I have at least two wordpress blogs on my own server. They are very similar, with the same theme.
    One, named « eva » , the other « Pierre » . They are not treated equally !!
    With my Iphone, within the wordpress App, I am successfull to add the « eva » blog after typing, name, password and Url to the list of blogs.
    Thru the apache log, I can see three exchanges
    [10/Feb/2014:19:16:07 +0100] "POST /xmlrpc.php HTTP/1.1" 200 5006
    [10/Feb/2014:19:16:08 +0100] "POST /xmlrpc.php HTTP/1.1" 200 9334
    [10/Feb/2014:19:16:09 +0100] "POST /xmlrpc.php HTTP/1.1" 200 10741

    But with the blog « Pierre », it is unsuccessful and I have only two exchanges
    [10/Feb/2014:20:44:28 +0100] "POST /xmlrpc.php HTTP/1.1" 200 5009
    [10/Feb/2014:20:44:29 +0100] "POST /xmlrpc.php HTTP/1.1" 200 9388

    To get more information, I have installed an sniffer/winPcap on my server to obtain the contents of the http messages.
    The first messages are different from the file size point of view but the contents are the same (even in hex) . See files http://ott.fr/xmlrpc/xmlrpc5006-eva.dat
    and http://ott.fr/xmlrpc/xmlrpc5009-pierre.dat

    The second messages seems to be complete from XML point of view with the specifics of each blog like title and so on.
    The only difference that I cant understand is the « double » attribute of the time zone of the successful file
    <member><name>time_zone</name><value><struct>
    <member><name>desc</name><value><string>Fuseau horaire</string></value></member>
    <member><name>readonly</name><value><boolean>1</boolean></value></member>
    <member><name>value</name><value><double>1</double></value></member>
    </struct></value></member>
    where the second file has
    <member><name>value</name><value><string>1</string></value></member>
    Both have « Paris « as time-zone.
    Both files finish with </methodResponse>. There are not truncated.
    You can see the files at http://ott.fr/xmlrpc/xmlrpc9334-eva.dat
    and http://ott.fr/xmlrpc/xmlrpc9385-pierre.dat

    Is it the reason there is not a third exchange, initiated by the IOS App ?

    The third file, is available only for the « Eva » blog. See http://ott.fr/xmlrpc/xmlrpc10741-eva.dat

    If you need access codes to this blog, please send me a mail at the temporary email : xmlrpc@ott.fr
    see also this file at http://ott.fr/xmlrpc/comments.pdf

  15. Addendum

    there are three hex caracters more at the beginning of the "bad" files : EF BB BF, before <?xml

    The question now are : why ?

  16. these bytes are the BOM : the Byte Order Mark (BOM)
    of the unicode to indicate it is UTF-8
    cf http://unicode.org/faq/utf_bom.html

  17. @didierott

    I've heard back from another user who'd reported a parse error. She reports the problem was apparently due to a plugin called Newest Twitter Widget by Fritz Wassen, and that the parse error went away after she removed this plugin.

    I haven't been able to find a copy of this plugin to test for myself, but on the off chance you have this plugin installed I wanted to mention it.

  18. Following up for @DigitalNaiv, since your hosted on WordPress.com the team had a few more troubleshooting resources at our disposal.

    The team was able to identify a server-side issue with the XML-RPC response sent from the WordPress.com servers to the app. An error on the server was truncating the XML data, making it invalid. The result was the parse error you've been seeing.

    The good news in this case is the WordPress.com folks are working on a patch which should be in place soon. Maybe give the app a try periodically over the next day or so and let us know if things being working as the should.

  19. Hi éric
    Thanks for your follow up
    I have not seen such "Newest Twitter " plugin in my differents blogs. Have you seen it on my site ? if yes, where?

    From what I have seen in the data flows (cf upper), sometimes the server send xml-rpc messages with BOM prefix due to the fact that the UTF-8 format is requested. This is appropriate rergarding the utf-8 standard.
    If you agree the presence of BOM, my understanding is that the application-side have to take into account the poitential presence of the "extra" caracteres.

    By the way, it could be interesting to understand why sometimes the UTF-8 BOM are not sent.
    didier

  20. @didierott

    I'm actually not sure what that widget looks like on a blog, just wanting to pass along info.

    There seem to be a few different things that can cause the parse error and we're looking into them as we find them.

    I'll keep replying here whenever we learn of a possible fix.

  21. just adding my site to ios wordpress app and i getting this error.

    now i even can not logon to my site. yes, i tried using desktop too, i tried reset password but nothing happen. is it because this error? or i do something else?

    please help.

  22. @didierott

    I think you were on the right track regarding the byte-order mark (BOM). We've encountered a few different blogs now where the XML-RPC response is being truncated because the server is inserting a BOM at the beginning of the response, but apparently not accounting for it in the response content length. The app can handle the BOM, but the server is truncating the response making the XML invalid. Ultimately, this is a server-side problem affecting a small % of blogs.

    The good news in all of this is we've found that if we specify an "Accept-Encoding: gzip,deflate" header in the XML-RPC request the BOM is omitted from the response, and the XML data is not truncated. (yay!) This is a patch we're including in the next release (out in a few weeks) and should help the folks affected by parse errors where this was the cause.

  23. Avoided

    I have found that my config.php file was an UTF-8 with BOM format
    with Notepad++ I converted it in UTF-8 no BOM
    And the BOM was now not generated by xml-rpx.php

  24. @didierott, That's great to hear. Glad you got it sorted and thanks for taking the time to update us!

  25. Hoping this might help someone avoid my frustration. In my case UTF-8 and BOM was not the culprit. After a lot of trial and error, I found that having any extra line-feeds in my functions.php file between multiple <?php ... ?> tags created problems with the XML being returned from xmlrpc.php: 1. it seemed to add extra whitespace/linefeeds before the XML doctype declaration; and 2. it also seemed to cut off the last few characters of the closing XML tag. I'm assuming that the extra whitespace/linefeeds above the doctype was also not being counted as part of the overall character count (much like the BOM issue above). So basically it seems like this problem is not just from BOM characters but anything before the returned XML doctype. Now why what is returned from xmlrpc.php is dependent on anything in functions.php I have no idea—I would think that they would be totally unrelated?! Very strange.

  26. Hi, could I get some help with this also? I have been on a plugin removing spree, have taken many of the steps above. Not sure what else to do, I'm not really sure what exactly I changed before this started happening. I have the advanced debug logs and would really appreciate the help if anyone is available to assist.

  27. Hi @rjentoft. I'm happy to help if I can. What's the URL of your site?

  28. Just to say that I was having this problem. By removing the site from within the Wordpress iOS app, and then re-adding it, the problem went away.

Topic Closed

This topic has been closed to new replies.


About this Topic