public function setMaxFilesize($maxFilesize = 'auto')
    {
        switch ($maxFilesize) {
            case 'auto':
                $maxFilesize = $this->convertToBytes(
                    ini_get('upload_max_filesize')
                );
                break;
        }

        $this->maxFilesize = $maxFilesize;
        $this->setAttribute('filesize', $maxFilesize);
    }
public function setMaxFilesize($maxFilesize = 'auto')
    {
        switch ($maxFilesize) {
            case 'auto':
                $maxFilesize = $this->convertToBytes(
                    ini_get('upload_max_filesize')
                );
                break;
        }

        $this->maxFilesize = $maxFilesize;
        $this->setAttribute('filesize', $maxFilesize);
    }
public function setMaxFilesize ( $ maxFilesize = 'auto' ) { switch ( $ maxFilesize ) { case 'auto' : $ maxFilesize = $ this -> convertToBytes ( ini_get ( 'upload_max_filesize' ) ) ; break ; } $ this -> maxFilesize = $ maxFilesize ; $ this -> setAttribute ( 'filesize' , $ maxFilesize ) ; }
Sets the maximum size in bytes a file is allowed to have.

@param int|string $maxFilesize The maximum allowed size in bytes

@author Benjamin Carl <opensource@clickalicious.de>

@return int The size in bytes
Sets the maximum size in bytes a file is allowed to have .