bb_sanitize_meta_key

Internal.

Description

bb_sanitize_meta_key( $key ); 

Parameters (1)

0. $key
The key.

Usage

  1. if ( !function_exists( 'bb_sanitize_meta_key' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'buddypress/bp-forums/bbpress/bb-includes/functions.bb-meta.php'; 
  3.  
  4. // The key. 
  5. $key = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = bb_sanitize_meta_key($key); 
  9.  

Defined (1)

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

/bp-forums/bbpress/bb-includes/functions.bb-meta.php  
  1. function bb_sanitize_meta_key( $key ) 
  2. return preg_replace( '|[^a-z0-9_]|i', '', $key );