Example #1
0
/**
 * Deletes a post style.
 *
 * @since  1.0.0
 * @access public
 * @param  int $post_id The post ID associated with the style to be deleted.
 * @return bool
 */
function carelib_delete_post_style($post_id)
{
    return delete_post_meta($post_id, carelib_get_post_style_meta_key());
}
Example #2
0
/**
 * Registers the library's custom metadata keys and sets up the sanitize
 * callback function.
 *
 * @since  1.0.0
 * @access public
 * @return void
 */
function carelib_register_post_style_meta()
{
    register_meta('post', carelib_get_post_style_meta_key(), 'sanitize_text_field', '__return_false');
}