Opened 3 years ago
Last modified 2 years ago
#15072 new defect (bug)
blogger.getRecentPosts drops backslashes
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Future Release |
| Component: | XML-RPC | Version: | 3.1 |
| Severity: | normal | Keywords: | has-patch |
| Cc: | daveabrahams |
Description
I have posts on my site containing fragments like:
[latex]\neg r(a,b)[/latex]
But when I pull them down using emacs weblogger-mode, the backslash is always missing. I edebug'ed way down into the bowels of the code and looked at the raw data arriving in the process buffer, and it was missing the backslash, so I'm pretty certain this is a WP bug and not something in emacs or weblogger-mode. Weblogger-mode is using the blogger API. I tried several other clients, and they seemed to work, but I assume they're using a different protocol (e.g. atom).
Attachments (1)
Change History (6)
comment:1
josephscott — 3 years ago
comment:2
daveabrahams — 3 years ago
- Cc daveabrahams added
Ha! I didn't think I'd be able to figure out how to test that, but I did, and it works (or at least, doesn't have the backslash problem ;->).
comment:3
daveabrahams — 3 years ago
Of course, unless my client is misusing it, the metaWeblog API's "editPost" method doesn't respect the "publish" flag sent as its last parameter. So I have to use blogger's API for that. Kinda weird.
- Milestone changed from Awaiting Review to Future Release
Attached removes some useless stripslashes() calls in blogger.getPost and blogger.getRecentPosts.
That said, the 'spec' for those two methods is terrible. Title and categories have to be included in the struct's content parameter, each enclosed in an encoded XML tag. So the title and categories technically should be doubly encoded, but WP doesn't do that, and doing so would probably break any clients that use these methods.
Encourage your client's author to switch to metaWeblog.*

Most XML-RPC clients use the metaWeblog.getRecentPosts method. Does this have the same problem?