/home/vianto5/cititower.mx/wp-content/plugins/wpml-wpforms/vendor/wpml/forms/classes/Hooks
NameSizeModeActions
Base.php23400644editdlrm
Registration.php15780644editdlrm
Edit: /home/vianto5/cititower.mx/wp-content/plugins/wpml-wpforms/vendor/wpml/forms/classes/Hooks/Base.php (2340B)
slug = $slug; $this->kind = $kind; $this->factory = $factory; } /** * Sets currently processed form ID. * * @param int $formId Currently processed form ID. */ public function setFormId( $formId ) { $this->formId = intval( $formId ); $this->package = null; } /** * Gets currently processed form ID. * * @return int */ protected function getFormId() { return $this->formId; } /** * Gets form ID from provided data. * * @param array $data Form data. * * @return int|null */ protected function getId( array $data ) { return array_key_exists( 'id', $data ) ? intval( $data['id'] ) : null; } /** * Creates and returns new translation package. * * @param int $formId Form ID. * * @return Package */ protected function newPackage( $formId ) { return $this->factory->getPackage( $formId, $this->kind ); } /** * Gets translation package. * * @return Package */ protected function getPackage() { if ( ! $this->package ) { $this->package = $this->newPackage( $this->formId ); } return $this->package; } /** * Checks if array value is not empty. * * @param mixed $key Key name. * @param mixed $array Associated array. * * @return bool */ protected function notEmpty( $key, $array ) { return is_string( $key ) && is_array( $array ) && array_key_exists( $key, $array ) && ! empty( $array[ $key ] ); } }