Opened 5 years ago
Closed 5 years ago
#7849 closed defect (bug) (fixed)
Fix settings category with apostrophe in metaWeblog.newPost (XML-RPC)
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Priority: | normal | Milestone: | 2.7 |
| Component: | XML-RPC | Version: | |
| Severity: | normal | Keywords: | has-patch |
| Cc: | josephscott |
Description
The problem was originally reported in the iPhone app ticket http://iphone.trac.wordpress.org/ticket/44
When setting a category with an apostrophe in it as part of a metaWeblog.newPost XML-RPC call that category gets skipped. The reason for this is that the apostrophe gets escaped twice, first at the XML-RPC level and second via prepare when generating the SQL query.
To fix this I've created a patch that calls stripslashes() on the category name before passing it to get_cat_ID().
Attachments (1)
Change History (4)
Note: See
TracTickets for help on using
tickets.
get_cat_ID() should probably do the stripping.