• Resolved danhgilmore

    (@danhgilmore)


    A user has a subsite and she cannot delete or edit her tags/cats. She is one of the admins of that site. When she tries, she gets the following error:

    “You need a higher level of permission.

    Sorry, you are not allowed to edit this item.”

    I’m a super admin on this WordPress multisite installation, and I get the same error. I’ve done some research, and I don’t know if I found a bug or not. Let me explain what I’ve done via an example.

    I want to delete the category named China. I went to the dashboard, Posts->Categories, and clicked delete. Received the error above.

    In the database:

    select count(*) from wp_X_terms;
    +----------+
    | count(*) |
    +----------+
    |      234 |
    +----------+
    1 row in set (0.13 sec)
    select * from wp_X_terms where name = 'china';
    +---------+-------+-------+------------+
    | term_id | name  | slug  | term_group |
    +---------+-------+-------+------------+
    |      39 | China | china |          0 |
    +---------+-------+-------+------------+
    1 row in set (0.13 sec)
    select * from wp_X_term_taxonomy where term_id = 39;
    +------------------+---------+----------+-------------+--------+-------+
    | term_taxonomy_id | term_id | taxonomy | description | parent | count |
    +------------------+---------+----------+-------------+--------+-------+
    |              962 |      39 | category |             | 118398 |    10 |
    |             1112 |      39 | post_tag |             |      0 |     8 |
    +------------------+---------+----------+-------------+--------+-------+
    2 rows in set (0.13 sec)

    We noticed that if a term had more than one entry in the wp_X_term_taxonomy category, it could not be edited via the UI.

    select t.name, tt.taxonomy, count(*) from wp_X_terms t inner join wp_X_term_taxonomy tt on t.term_id = tt.term_id group by tt.term_id having count(*) > 1;
    +----------------+----------+----------+
    | name           | taxonomy | count(*) |
    +----------------+----------+----------+
    | China          | category |        2 |
    | Exercise       | category |        2 |
    | Product Line   | category |        3 |
    | Popular Topics | category |        2 |
    +----------------+----------+----------+

    (There were quite a few more results, but I truncated for brevity.)

    Am I missing something, or is this a bug in WordPress?

Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Cannot edit/delete terms’ is closed to new replies.