Home > database >  Adding a Custom Checkbox to the Post “Publish” Box of wordpress
Adding a Custom Checkbox to the Post “Publish” Box of wordpress

Time:10-26

Thanks to an article I found enter image description here

CodePudding user response:

You're missing the quotes in your add_action functions for the callback. That's why it thinks it is an undefined constant.

add_action('post_submitbox_misc_actions', 'createCheckBoxField');

Ref: https://developer.wordpress.org/reference/functions/add_action/

  • Related