cf7_post

Insert a $_POST variable (submitted form value).

Description

cf7_post( $atts ); 

Parameters (1)

0. $atts
The atts.

Usage

  1. if ( !function_exists( 'cf7_post' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'contact-form-7-dynamic-text-extension/contact-form-7-dynamic-text-extension.php'; 
  3.  
  4. // The atts. 
  5. $atts = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = cf7_post($atts); 
  9.  

Defined (1)

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

/contact-form-7-dynamic-text-extension.php  
  1. function cf7_post($atts) { 
  2. extract(shortcode_atts(array( 
  3. 'key' => -1,  
  4. ), $atts)); 
  5. if($key == -1) return ''; 
  6. $val = ''; 
  7. if( isset( $_POST[$key] ) ) { 
  8. $val = $_POST[$key]; 
  9. return $val;