NF_MergeTags_Form

Class NF_MergeTags_Form.

Defined (1)

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

/includes/MergeTags/Form.php  
  1. final class NF_MergeTags_Form extends NF_Abstracts_MergeTags 
  2. protected $id = 'form'; 
  3.  
  4. protected $sub_seq; 
  5.  
  6. public function __construct() 
  7. parent::__construct(); 
  8. $this->title = __( 'Form', 'ninja-forms' ); 
  9.  
  10. $this->merge_tags = Ninja_Forms()->config( 'MergeTagsForm' ); 
  11.  
  12. add_action( 'ninja_forms_save_sub', array( $this, 'setSubSeq' ) ); 
  13.  
  14. /** 
  15. * @return mixed 
  16. */ 
  17. public function getSubSeq() 
  18. return $this->sub_seq; 
  19.  
  20. /** 
  21. * @param mixed $sub_seq 
  22. */ 
  23. public function setSubSeq( $sub_id ) 
  24. $submission = Ninja_Forms()->form()->sub( $sub_id )->get(); 
  25. $this->sub_seq = $submission->get_seq_num(); 
  26.  
  27. } // END CLASS NF_MergeTags_Form