WPCF7_Pipe

The Contact Form 7 WPCF7 Pipe class.

Defined (1)

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

/includes/pipe.php  
  1. class WPCF7_Pipe { 
  2.  
  3. public $before = ''; 
  4. public $after = ''; 
  5.  
  6. public function __construct( $text ) { 
  7. $text = (string) $text; 
  8.  
  9. $pipe_pos = strpos( $text, '|' ); 
  10.  
  11. if ( false === $pipe_pos ) { 
  12. $this->before = $this->after = trim( $text ); 
  13. } else { 
  14. $this->before = trim( substr( $text, 0, $pipe_pos ) ); 
  15. $this->after = trim( substr( $text, $pipe_pos + 1 ) );