PHP 클래스 Horde_Form_Type_image, horde

상속: extends Horde_Form_Type
파일 보기 프로젝트 열기: horde/horde

공개 프로퍼티들

프로퍼티 타입 설명
$_img array Hash containing the previously uploaded image info.
$_max_filesize integer Limit the file size?
$_random string A random id that identifies the image information in the session data.
$_show_keeporig boolean Show the option to upload also original non-modified image?
$_show_upload boolean Show the upload button?
$_uploaded boolean Has a file been uploaded on this form submit?

공개 메소드들

메소드 설명
_getUpload ( Horde_Variables &$vars, Horde_Form_Variable &$var ) Gets the upload and sets up the upload data array. Either fetches an upload done with this submit or retrieves stored upload info.
about ( ) Return info about field type.
getImage ( Horde_Variables $vars, Horde_Form_Variable $var ) : array Returns the current image information.
getInfo ( &$vars, &$var, &$info )
getRandomId ( )
getUploadedFileType ( $field )
init ( $show_upload = true, $show_keeporig = false, $max_filesize = null )
isValid ( Horde_Form_Variable &$var, Horde_Variables &$vars, array $value, something &$message )
loadImageData ( array &$image ) Loads any existing image data into the image field. Requires that the array $image passed to it contains the structure: $image['load']['file'] - the filename of the image; $image['load']['data'] - the raw image data.
onSubmit ( &$var, &$vars )

메소드 상세

_getUpload() 공개 메소드

Gets the upload and sets up the upload data array. Either fetches an upload done with this submit or retrieves stored upload info.
public _getUpload ( Horde_Variables &$vars, Horde_Form_Variable &$var )
$vars Horde_Variables The form state to check this field for
$var Horde_Form_Variable The Form field object to check

about() 공개 메소드

Return info about field type.
public about ( )

getImage() 공개 메소드

Returns the current image information.
public getImage ( Horde_Variables $vars, Horde_Form_Variable $var ) : array
$vars Horde_Variables The form state to check this field for
$var Horde_Form_Variable The Form field object to check
리턴 array The current image hash.

getInfo() 공개 메소드

public getInfo ( &$vars, &$var, &$info )

getRandomId() 공개 메소드

public getRandomId ( )

getUploadedFileType() 공개 메소드

public getUploadedFileType ( $field )

init() 공개 메소드

public init ( $show_upload = true, $show_keeporig = false, $max_filesize = null )

isValid() 공개 메소드

public isValid ( Horde_Form_Variable &$var, Horde_Variables &$vars, array $value, something &$message )
$var Horde_Form_Variable The Form field object to check
$vars Horde_Variables The form state to check this field for
$value array The field value array - should contain a key ['hash'] which holds the key for the image on temp storage
$message something Not clear what this field does

loadImageData() 공개 메소드

Loads any existing image data into the image field. Requires that the array $image passed to it contains the structure: $image['load']['file'] - the filename of the image; $image['load']['data'] - the raw image data.
public loadImageData ( array &$image )
$image array The image array.

onSubmit() 공개 메소드

public onSubmit ( &$var, &$vars )

프로퍼티 상세

$_img 공개적으로 프로퍼티

Hash containing the previously uploaded image info.
public array $_img
리턴 array

$_max_filesize 공개적으로 프로퍼티

Limit the file size?
public int $_max_filesize
리턴 integer

$_random 공개적으로 프로퍼티

A random id that identifies the image information in the session data.
public string $_random
리턴 string

$_show_keeporig 공개적으로 프로퍼티

Show the option to upload also original non-modified image?
public bool $_show_keeporig
리턴 boolean

$_show_upload 공개적으로 프로퍼티

Show the upload button?
public bool $_show_upload
리턴 boolean

$_uploaded 공개적으로 프로퍼티

Has a file been uploaded on this form submit?
public bool $_uploaded
리턴 boolean