save_meta_settings

Instellingen bewaren.

Description

save_meta_settings( $post_id ); 

Parameters (1)

0. $post_id
The post id.

Usage

  1. if ( !function_exists( 'save_meta_settings' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'woocommerce-upload-my-file/inc/umf-funct.php'; 
  3.  
  4. // The post id. 
  5. $post_id = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = save_meta_settings($post_id); 
  9.  

Defined (1)

The function is defined in the following location(s).

/inc/umf-funct.php  
  1. function save_meta_settings( $post_id ) { 
  2. if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return; 
  3. if ( !isset( $_POST['woo_umf_nonce'] ) || !wp_verify_nonce( $_POST['woo_umf_nonce'], 'woo_umf_nonce' ) ) return; 
  4. update_post_meta( $post_id, '_woo_umf_enable', (int) $_POST['_woo_umf_enable'] );