ddw_wcde_woocommerce_is_informal

Detects WooCommerce settings and returns TRUE or FALSE.

Description

(boolean) ddw_wcde_woocommerce_is_informal(); 

Returns (boolean)

TRUE if informal translations should be loaded, FALSE if not.


Usage

  1. if ( !function_exists( 'ddw_wcde_woocommerce_is_informal' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'woocommerce-german-de_de/includes/wcde-functions.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = ddw_wcde_woocommerce_is_informal(); 
  7.  

Defined (1)

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

/includes/wcde-functions.php  
  1. function ddw_wcde_woocommerce_is_informal() { 
  2.  
  3. /** Get the option from WooCommerce settings */ 
  4. $wcde_lang_type = ( 'no' === get_option( 'wcde_german_formal' ) ) ? TRUE : FALSE; 
  5.  
  6. /** Return TRUE or FALSE based on setting */ 
  7. return $wcde_lang_type; 
  8.  
  9. } // end of function ddw_wcde_woocommerce_is_informal