Change WordPress user roles and capabilities Forums Bug Reports Default post category affected by individual user category/taxonomy ID settings

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #4634
    City Dev
    Participant

    When providing category/taxonomy IDs for an individual user, the first ID in the list becomes checked by default when a user creates a new post. The expected functionality is that no categories/taxonomies would be selected by default.

    I haven’t attempted the standard troubleshooting techniques to see if any other plugins contribute to the the problem. On first look, my assumption is that it’s isolated to URE.

    #4635
    Vladimir
    Keymaster

    Right, URE’s edit restrictions add-on works this way by design. I have a strong reason for this behavior, not one expected by you.

    When you input category ID to the user profile such user is allowed to edit just post with that category ID. When user adds new post WordPress added a new post record and then re-open it for editing as the existing post. If this post will not have at least one category from the list of allowed for this user, user will not can to proceed with new added post due to edit restrictions applied to him.

    URE assigns to the new added post the 1st category from the list of allowed categories automatically exactly for the reason described above.

    #4637
    City Dev
    Participant

    If WordPress auto-selected a category as part of it’s typical behavior, this would have gone unnoticed. The fact that it isn’t normal behavior is what made it present as a bug.

    Requiring a category ID that the user has permission to edit makes sense. However, a user can still lose access to the post by deselecting the default category and then saving/publishing. The post then uses the default category set in WordPress settings. If the user doesn’t have access to the default WordPress category, then they are unable to edit the post they just created.

    I’m not sure what all you’re able to control in the WordPress admin. At a minimum, requiring the default category be assigned based on the users settings would seem necessary to make this approach work without a user being able to circumvent it. To me, a more user friendly approach would be to disable the publish/draft buttons with a small note indicating that selecting a category is required.

    #4643
    Vladimir
    Keymaster

    While I may agree with you thoughts about user experience, I do not see currently the alternative to auto assign category to a new post created by a restricted user.
    Ability to select a default category from the list of allowed categories sounds good for me. Thank for the suggestion. I will take this into account.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.