wc_generator_tag

Output generator tag to aid debugging.

Description

wc_generator_tag( $gen, $type ); 

Parameters (2)

0. $gen
The gen.
1. $type
The type.

Usage

  1. if ( !function_exists( 'wc_generator_tag' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'woocommerce/includes/wc-template-functions.php'; 
  3.  
  4. // The gen. 
  5. $gen = null; 
  6.  
  7. // The type. 
  8. $type = null; 
  9.  
  10. // NOTICE! Understand what this does before running. 
  11. $result = wc_generator_tag($gen, $type); 
  12.  

Defined (1)

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

/includes/wc-template-functions.php  
  1. function wc_generator_tag( $gen, $type ) { 
  2. switch ( $type ) { 
  3. case 'html': 
  4. $gen .= "\n" . '<meta name="generator" content="WooCommerce ' . esc_attr( WC_VERSION ) . '">'; 
  5. break; 
  6. case 'xhtml': 
  7. $gen .= "\n" . '<meta name="generator" content="WooCommerce ' . esc_attr( WC_VERSION ) . '" />'; 
  8. break; 
  9. return $gen;