wpseo_dismiss_tagline_notice

Hides the default tagline notice for a specific user.

Description

wpseo_dismiss_tagline_notice(); 

Usage

  1. if ( !function_exists( 'wpseo_dismiss_tagline_notice' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'yoast-seo/admin/ajax.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = wpseo_dismiss_tagline_notice(); 
  7.  

Defined (1)

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

/admin/ajax.php  
  1. function wpseo_dismiss_tagline_notice() { 
  2. if ( ! current_user_can( 'manage_options' ) ) { 
  3. die( '-1' ); 
  4.  
  5. check_ajax_referer( 'wpseo-dismiss-tagline-notice' ); 
  6.  
  7. update_user_meta( get_current_user_id(), 'wpseo_seen_tagline_notice', 'seen' ); 
  8.  
  9. die( '1' );