pmpro_wp_mail_from_name

Nicer default emails.

Description

pmpro_wp_mail_from_name( (string) $from_name ); 

Parameters (1)

0. $from_name (string)
The from name.

Usage

  1. if ( !function_exists( 'pmpro_wp_mail_from_name' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'paid-memberships-pro/includes/email.php'; 
  3.  
  4. // The from name. 
  5. $from_name = ''; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = pmpro_wp_mail_from_name($from_name); 
  9.  

Defined (1)

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

/includes/email.php  
  1. function pmpro_wp_mail_from_name($from_name) 
  2. $default_from_name = 'WordPress'; 
  3.  
  4. //make sure it's the default from name 
  5. if($from_name == $default_from_name) 
  6. {  
  7. $pmpro_from_name = pmpro_getOption("from_name"); 
  8. if ($pmpro_from_name) 
  9. $from_name = stripslashes($pmpro_from_name); 
  10.  
  11. return $from_name;