#20473 closed defect (bug) (invalid)
cap fixes in mw_editpost
| Reported by: | nprasath002 | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | XML-RPC | Version: | 3.4 |
| Severity: | critical | Keywords: | has-patch |
| Cc: | Focuses: |
Description
the patch includes
- moved the cap check below post type check (first we need to check the post type for capability check)
- expand the cap check for pages
- check cap for publishing post or setting it as private with post_ID
The checks were ok in 3.3 but changed in the trunk which breaks support for 'pages'.
Attachments (2)
Change History (11)
#2
@
14 years ago
Just replaced the dynamic strings with post.
A more elaborate error message needs more boilerplate code.
I am not sure we need this?
#3
@
14 years ago
I'd suggest "You are not allowed to edit this item", which is already used in several files:
http://core.trac.wordpress.org/browser/tags/3.3.1/wp-admin/post.php#L137
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
__( "Sorry, you do not have the right to edit this {$post_type}." )A dynamic string like that is not translatable, see #19099 or #20005 for example.