PHP 클래스 Pocket, addons

파일 보기 프로젝트 열기: vanilla/addons 1 사용 예제들

공개 프로퍼티들

프로퍼티 타입 설명
$Body $var string The text to display in the pocket.
$Disabled Whether or not the pocket is disabled. The pocket can also be in testing-mode.
$EmbeddedNever $var bool Whether to disable the pocket for embedded comments. *
$Format The format of the pocket.
$Location $var string The location on the page to display the pocket.
$MobileNever $var array The repeat frequency.
$MobileOnly $var array The repeat frequency.
$Name $var string A descriptive name for the pocket to help keep it organized.
$NameTranslations array
$Page $var string The name of the page to put the pocket on.
$RepeatFrequency $var array The repeat frequency.
$RepeatType $var string How the pocket repeats on the page.
$ShowInDashboard boolean
$Type $var string Pocket type

공개 메소드들

메소드 설명
__construct ( string $Location = '' ) Pocket constructor.
canRender ( array $Data ) : boolean Whether or not this pocket should be processed based on its state.
isAd ( ) : boolean Determine whether the pocket is of type 'ad'.
load ( array $Data ) Load the pocket's data from an array.
pageName ( null $NameOrObject = null ) : mixed | null | string
parseRepeat ( $Repeat ) : array
render ( array $Data = NULL ) Render the pocket to the page.
repeat ( string $Type, integer | array $Frequency ) Set the repeat of the pocket.
toString ( null $Data = NULL ) : mixed | string
touch ( $Name, $Value )

메소드 상세

__construct() 공개 메소드

Pocket constructor.
public __construct ( string $Location = '' )
$Location string

canRender() 공개 메소드

Whether or not this pocket should be processed based on its state.
public canRender ( array $Data ) : boolean
$Data array Data specific to the request.
리턴 boolean

isAd() 공개 메소드

Determine whether the pocket is of type 'ad'.
public isAd ( ) : boolean
리턴 boolean

load() 공개 메소드

Load the pocket's data from an array.
public load ( array $Data )
$Data array

pageName() 공개 정적인 메소드

public static pageName ( null $NameOrObject = null ) : mixed | null | string
$NameOrObject null
리턴 mixed | null | string

parseRepeat() 공개 정적인 메소드

public static parseRepeat ( $Repeat ) : array
$Repeat
리턴 array

render() 공개 메소드

@param array $Data additional data for the pocket.
public render ( array $Data = NULL )
$Data array

repeat() 공개 메소드

@param string $Type The repeat type, contained in the various Pocket::REPEAT_* constants. - every: Repeats every x times. If $Frequency is an array then it will be interpretted as array($Frequency, $Begin). - indexes: Renders only at the given indexes, starting at 1.
public repeat ( string $Type, integer | array $Frequency )
$Type string
$Frequency integer | array The frequency of the repeating, see the $Type parameter for how this works.

toString() 공개 메소드

public toString ( null $Data = NULL ) : mixed | string
$Data null
리턴 mixed | string

touch() 공개 정적인 메소드

public static touch ( $Name, $Value )
$Name
$Value

프로퍼티 상세

$Body 공개적으로 프로퍼티

$var string The text to display in the pocket.
public $Body

$Disabled 공개적으로 프로퍼티

Whether or not the pocket is disabled. The pocket can also be in testing-mode.
public $Disabled

$EmbeddedNever 공개적으로 프로퍼티

$var bool Whether to disable the pocket for embedded comments. *
public $EmbeddedNever

$Format 공개적으로 프로퍼티

The format of the pocket.
public $Format

$Location 공개적으로 프로퍼티

$var string The location on the page to display the pocket.
public $Location

$MobileNever 공개적으로 프로퍼티

$var array The repeat frequency.
public $MobileNever

$MobileOnly 공개적으로 프로퍼티

$var array The repeat frequency.
public $MobileOnly

$Name 공개적으로 프로퍼티

$var string A descriptive name for the pocket to help keep it organized.
public $Name

$NameTranslations 공개적으로 정적으로 프로퍼티

public static array $NameTranslations
리턴 array

$Page 공개적으로 프로퍼티

$var string The name of the page to put the pocket on.
public $Page

$RepeatFrequency 공개적으로 프로퍼티

$var array The repeat frequency.
public $RepeatFrequency

$RepeatType 공개적으로 프로퍼티

$var string How the pocket repeats on the page.
public $RepeatType

$ShowInDashboard 공개적으로 프로퍼티

public bool $ShowInDashboard
리턴 boolean

$Type 공개적으로 프로퍼티

$var string Pocket type
public $Type