- fixed dynamically declared variables inside the classes;

This commit is contained in:
Mykyta Synelnikov
2023-04-17 20:16:15 +03:00
parent 1a219ebb24
commit 034d9e8b43
22 changed files with 275 additions and 147 deletions
+21 -17
View File
@@ -13,43 +13,47 @@ if ( ! class_exists( 'um\core\Form' ) ) {
*/
class Form {
/**
* @var null
*/
public $form_suffix;
public $form_suffix = null;
/**
* @var
*/
var $form_id;
public $form_id;
/**
* @var null
*/
var $post_form = null;
public $post_form = null;
/**
* @var null
*/
public $nonce = null;
var $nonce = null;
/**
* @var null
*/
public $errors = null;
/**
* @var null
*/
public $processing = null;
/**
* @var array
*/
public $all_fields = array();
/**
* Form constructor.
*/
function __construct() {
$this->form_suffix = null;
$this->errors = null;
$this->processing = null;
public function __construct() {
add_action( 'template_redirect', array( &$this, 'form_init' ), 2 );
add_action( 'init', array( &$this, 'field_declare' ), 10 );
}