src/Field.php
public function __tostring() {
        // Prepare field label
        if (!$this->label)
            $this->label = $this->name;
        // Prepare errors
        $errors = [];
        foreach ((array) $this->errors as $error) {
            // Get Html code by $error
            $errors[] = $this->renderError($error);
        }
        // Implode errors
        $this->errors = implode('', $errors);
        // Prepare the object for rendering
        $this->prepare();
        // Make html code related to the attributes
        $this->attributes = static::array2attrs($this->attributes);
        // Return rendered field
        return $this->renderField();
    }
public function __tostring() {
        // Prepare field label
        if (!$this->label)
            $this->label = $this->name;
        // Prepare errors
        $errors = [];
        foreach ((array) $this->errors as $error) {
            // Get Html code by $error
            $errors[] = $this->renderError($error);
        }
        // Implode errors
        $this->errors = implode('', $errors);
        // Prepare the object for rendering
        $this->prepare();
        // Make html code related to the attributes
        $this->attributes = static::array2attrs($this->attributes);
        // Return rendered field
        return $this->renderField();
    }
public function __tostring ( ) { // Prepare field label
 if ( ! $ this -> label ) $ this -> label = $ this -> name ; // Prepare errors
 $ errors = [ ] ; foreach ( ( array ) $ this -> errors as $ error ) { // Get Html code by $error
 $ errors [ ] = $ this -> renderError ( $ error ) ; } // Implode errors
 $ this -> errors = implode ( '' , $ errors ) ; // Prepare the object for rendering
 $ this -> prepare ( ) ; // Make html code related to the attributes
 $ this -> attributes = static :: array2attrs ( $ this -> attributes ) ; // Return rendered field
 return $ this -> renderField ( ) ; }
Prepare some config and render element

@uses self::prepareAttributes() to make html code related to the attributes
@uses self::array2attrs() to make html code related to the attributes

@category Rendering

@return string Rendered element
Prepare some config and render element