Swat/SwatForm.php
public function getHiddenField($name)
    {
        $data = null;

        if (isset($this->hidden_fields[$name])) {
            // Get value of a hidden field we've already unserialized after
            // processing this form.
            $data = $this->hidden_fields[$name];
        } elseif (!$this->processed && $this->isSubmitted()) {
            // Otherwise, make sure this form was processed and get hidden
            // field from raw form data.
            $raw_data = $this->getFormData();
            $serialized_field_name = self::SERIALIZED_PREFIX . $name;
            if (isset($raw_data[$serialized_field_name])) {
                $data = $this->unserializeHiddenField(
                    $raw_data[$serialized_field_name]
                );
            }
        }

        return $data;
    }
public function getHiddenField($name)
    {
        $data = null;

        if (isset($this->hidden_fields[$name])) {
            // Get value of a hidden field we've already unserialized after
            // processing this form.
            $data = $this->hidden_fields[$name];
        } elseif (!$this->processed && $this->isSubmitted()) {
            // Otherwise, make sure this form was processed and get hidden
            // field from raw form data.
            $raw_data = $this->getFormData();
            $serialized_field_name = self::SERIALIZED_PREFIX . $name;
            if (isset($raw_data[$serialized_field_name])) {
                $data = $this->unserializeHiddenField(
                    $raw_data[$serialized_field_name]
                );
            }
        }

        return $data;
    }
public function getHiddenField ( $ name ) { $ data = null ; if ( isset ( $ this -> hidden_fields [ $ name ] ) ) { // Get value of a hidden field we've already unserialized after // processing this form. $ data = $ this -> hidden_fields [ $ name ] ; } elseif ( ! $ this -> processed && $ this -> isSubmitted ( ) ) { // Otherwise, make sure this form was processed and get hidden // field from raw form data. $ raw_data = $ this -> getFormData ( ) ; $ serialized_field_name = self :: SERIALIZED_PREFIX . $ name ; if ( isset ( $ raw_data [ $ serialized_field_name ] ) ) { $ data = $ this -> unserializeHiddenField ( $ raw_data [ $ serialized_field_name ] ) ; } } return $ data ; }
Gets the value of a hidden form field

@param string $name the name of the field whose value to get.

@return mixed the value of the field. The type of the field is preserved
from the call to {@link SwatForm::addHiddenField()}. If
the field does not exist, null is returned.

@throws SwatInvalidSerializedDataException if the serialized form data
does not match the signature
data.

@see SwatForm::addHiddenField()
Gets the value of a hidden form field