cptbc_mb_save_details

The CPT Bootstrap Carousel cptbc mb save details function.

Description

cptbc_mb_save_details(); 

Usage

  1. if ( !function_exists( 'cptbc_mb_save_details' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'cpt-bootstrap-carousel/cptbc-admin.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = cptbc_mb_save_details(); 
  7.  

Defined (1)

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

/cptbc-admin.php  
  1. function cptbc_mb_save_details() { 
  2. global $post; 
  3. if (isset($_POST["cptbc_image_url"])) { 
  4. $openblank = 0; 
  5. if(isset($_POST["cptbc_image_url_openblank"]) && $_POST["cptbc_image_url_openblank"] == '1') { 
  6. $openblank = 1; 
  7. update_post_meta($post->ID, "cptbc_image_url", esc_url($_POST["cptbc_image_url"])); 
  8. update_post_meta($post->ID, "cptbc_image_url_openblank", $openblank); 
  9. update_post_meta($post->ID, "cptbc_image_link_text", sanitize_text_field($_POST["cptbc_image_link_text"]));