• Hi,
    First off, i like the UI.
    Coming to my problem, I have a custom post type events-api, where I enabled all the custom meta fields to be exposed/enabled, but when I click Save, the post type is disabled and all the changes I made on that page are disabled.
    I’ve done this several times and with different custom post types, but no luck.

    Would appreciate any help

Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Contributor yikesitskevin

    (@yikesitskevin)

    Hi @conradsa,

    How are you creating the custom post type? Is it through a plugin? What happens in a lot of instances is a plugin is overriding our plugin’s REST values and is therefore turning off the REST API after we’re enabling it.

    Let me know.

    Thank you,
    Kevin.

    Thread Starter conradsa

    (@conradsa)

    Hi @yikesitskevin
    I created the custom post type manually through code in the standard way. I am not sure which plugin is disabling the REST API, but let me do a bit of detective work and figure it out.

    Thanks for the quick reply.

    Plugin Contributor yikesitskevin

    (@yikesitskevin)

    If you’ve created the post type yourself then this shouldn’t happen… What hook are you using to call the register_post_type function?

    Hi there!

    I have exactly the same issue. I enabled all the post type and taxonomies meta fields to be exposed/enabled, but when I click Save, the taxonomies are all disabled again.

    First time I activated the plugin, some where enabled but as soon as I change something, they go disabled except a few post type meta fields.

    I haven’t crated any custom post type, all of them come from plugins.

    I basically use WP Job Manager as the site is a job board.

    Any idea how to fix this?

    All help will be appreciated ??

    Plugin Contributor yikesitskevin

    (@yikesitskevin)

    Hi @sergimv,

    I am not sure why this seems to be happening to a lot of people.

    My guess is that we’re saving the endpoints as enabled and this value is being overwritten by plugin which fire off later.

    We’re running our hook at a priority level of 100, which is fairly low (i.e. runs after most other hooks) so I don’t understand. Also, I can’t replicate this issue in my environments (even when using a variety of CPT-creating plugins).

    Do you have any caching on the site? On the admin side of the site? I wouldn’t be surprised if some hosts/plugins heavily cache CPT definitions.

    All the best,
    Kevin.

    Thread Starter conradsa

    (@conradsa)

    Hi @yikesitskevin & @sergimv

    An update to my issue:
    I disabled all plugins and went to the default theme, and checked the plugin. The issue was the same. The caching was disabled.

    I am using add action to call the custom post type. I haven’t changed it since its was similar to a another post type created through CPT. This plugin has since been uninstalled and deleted.

    I tried the plugin on another site and the same thing happened. That site is on AWS and no caching is enabled on the server.

    I am not sure where I need to look for a fix.

    Thanks,
    Conrad.

    Plugin Contributor yikesitskevin

    (@yikesitskevin)

    Hi Conrad,

    What action are you using to register the post type? What is the priority of the action? Can you show me the add_action call and the associated function you’re using? Also, where is this add_action call located? Is it in functions.php?

    Thank you,
    Kevin.

    Hi @yikesitskevin & @conradsa

    I also disabled all plugins. The issue was the same. The caching was disabled as well.

    I basically tried everything and this time I’m completely lost on how to fix this ??

    I tested the plugin on other wp domains hosted on same server and they worked well. I installed the same theme and plugins on other site and I’ve been able to activate endpoints. I don’t know why it doesn’t work on the site I really need it.

    I hope I can make it someday.

    Sergi

    Plugin Contributor yikesitskevin

    (@yikesitskevin)

    Hi Sergi,

    That’s really bizarre. Have you tried deleting our plugin and re-installing it? It sounds like something is “stuck.”

    I am really not sure what’s going on…

    I still have the same problem… would really appreciate to find a solution.

    Hey Guys,
    im new here in wordpress but i think is the size of POST of the page settings. I have 31 endpoints (custom post type) to be configured in Settings Page.When I change this to enabled, if it is one of the first of the listing, it works, when it is at the end of the list, this does not work.

    I Have a suggestion to plugin. It Can post only enableds endpoint to reduce the post size to server.

    Plugin Contributor yikesitskevin

    (@yikesitskevin)

    @lucasargate,

    That’s makes sense if you have that many post types (that’s a lot of post types!). There are most likely hundreds or thousands of meta fields you’re enabling/disabling.

    Instead of making only enabled endpoints POST to the server (how would you disable them then?) the plugin should instead save data via AJAX – that would improve the user experience and avoid this problem.

    That’s a larger project though.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Cannot enable visibility of custom post type’ is closed to new replies.