Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter anonmeimei

    (@anonmeimei)

    Okay, the problem seems to have come up due to a conflict with the ACF Extended plugin. The problem disappeared after I deactivated ACFE…

    Hello @anonmeimei,

    ACF Extended developer here! I just tried to use Custom Post Type Permalinks with ACF Extended on a blank WP install and I don’t get any warning/error when saving a custom post type. Can you please re-publish the warning message you get (your initial screenshot is unavailable), so I could try to find the cause of the issue?

    Thanks in advance.

    Have a nice day!

    Regards.

    Thread Starter anonmeimei

    (@anonmeimei)

    Okay, looks I made a mistake. The error wasn’t caused by ACFE. Sorry about that @hwk-fr . The error not showing up while ACFE was disabled was just a coincidence, because right now, the errors are showing up again:

    Trying to access array offset on value of type bool in …\public\wp-content\plugins\custom-post-type-permalinks\CPTP\Module\Permalink.php on line 417

    and several header info errors…

    Warning: Cannot modify header information – headers already sent by (output started at …\Local Sites\…..\app\public\wp-content\plugins\custom-post-type-permalinks\CPTP\Module\Permalink.php:417) in …\Local Sites\…\app\public\wp-admin\post.php on line 231

    Warning: Cannot modify header information – headers already sent by (output started at ….\Local Sites\….\app\public\wp-content\plugins\custom-post-type-permalinks\CPTP\Module\Permalink.php:417) in …\Local Sites\…\app\public\wp-admin\post.php on line 1340

    Warning: Cannot modify header information – headers already sent by (output started at ….\Local Sites\….\app\public\wp-content\plugins\custom-post-type-permalinks\CPTP\Module\Permalink.php:417) in …\Local Sites\…\app\public\wp-admin\post.php on line 1343

    Hello,

    Okay good to hear. Regarding your issue, it indeed looks like a bug within the Custom Post Permalinks plugin. I will let the author take care of it.

    What I can recommend tho is to hide errors on screen, and enable logs instead. This method has the advantage to remove the additional “Warning: Cannot modify header information” warnings, which are a side effect of displaying errors on screen, and which can break other functionalities on your website (redirections etc…).

    In order to enable logs, you can add the following code in your wp-config.php file:

    define('WP_DEBUG', true); // enable debug
    define('WP_DEBUG_LOG', true); // enable logs
    define('WP_DEBUG_DISPLAY', false); // disable on screen errors
    

    You’ll then find errors and warnings in the /wp-content/debug.log file.
    See WP_DEBUG documentation.

    Hope it helps!

    Have a nice day!

    Regards.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Error warning upon saving/publishing custom post type draft’ is closed to new replies.