Error 400 when editing custom post type

Support General Error 400 when editing custom post typeResolved

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #37010
    ArnoArno
    Participant

    Hi,

    My browser console throws errors with status code 400 when it requests URLs like the below ones, when editing a custom post:
    https://www.example.com/wp-json/wp/v2/activity?context=view&per_page=20&orderby=count&order=desc&_fields=id%2Cname&search=pila&_locale=user

    https://www.example.com/wp-includes/js/dist/api-fetch.min.js?ver=63050163caffa6aac54e9ebf21fe0472

    Because of this, I can't assign taxonomy terms to the post, because the box does not auto-populate as I type.

    The problem does not occur when I edit a post type with no custom fields or taxonomies involved.

    The problem does not occur on another website on the same server without Meta Box.

    This is MB 5.4.6 and MB AIO 1.16.2.

    #37026
    Long NguyenLong Nguyen
    Moderator

    Hi,

    Firstly, please re-save the permalink settings (Post name) and recheck this issue. If it does not help, please share the code that creates the post type on your site. I will help you to check this.

    #37029
    ArnoArno
    Participant

    Hi Long,

    Sorry, I am not exactly sure what I need to do. Go to the post in edit mode and save again? I did, but that didn't help. Or do I need to change the permalink? The problem is not restricted to one post.

    How do I get the code that creates the post type? I used MB Custom Post Types & Custom Taxonomies to create it.

    #37038
    ArnoArno
    Participant

    I found the issue. The taxonomy had the same slug as a custom post type. I did not realize that when creating it, and there's no error or warning for mistakes like this.

    #37039
    ArnoArno
    Participant

    And it seems to only become a problem once the taxonomy is associated with the post type.

    #37049
    Long NguyenLong Nguyen
    Moderator

    Hi,

    Thanks for more information.

    So you can just change the custom taxonomy slug with another one to make it works properly.

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