PHP 트레잇 yii\bootstrap\BootstrapWidgetTrait

Note: class, which uses this trait must declare public field named options with the array default value: php class MyWidget extends \yii\base\Widget { use BootstrapWidgetTrait; public $options = []; } This field is not present in the trait in order to avoid possible PHP Fatal error on definition conflict.
부터: 2.0.6
저자: Antonio Ramirez ([email protected])
저자: Qiang Xue ([email protected])
저자: Paul Klimov ([email protected])
파일 보기 프로젝트 열기: yiisoft/yii2-bootstrap

공개 프로퍼티들

프로퍼티 타입 설명
$clientEvents the event handlers for the underlying Bootstrap JS plugin. Please refer to the corresponding Bootstrap plugin Web page for possible events. For example, this page shows how to use the "Modal" plugin and the supported events (e.g. "shown").
$clientOptions the options for the underlying Bootstrap JS plugin. Please refer to the corresponding Bootstrap plugin Web page for possible options. For example, this page shows how to use the "Modal" plugin and the supported options (e.g. "remote").

공개 메소드들

메소드 설명
getView ( ) : View
init ( ) Initializes the widget.

보호된 메소드들

메소드 설명
registerClientEvents ( ) Registers JS event handlers that are listed in [[clientEvents]].
registerPlugin ( string $name ) Registers a specific Bootstrap plugin and the related events

메소드 상세

getView() 추상적인 공개 메소드

또한 보기: yii\base\Widget::getView()
abstract public getView ( ) : View
리턴 yii\web\View the view object that can be used to render views or view files.

init() 공개 메소드

This method will register the bootstrap asset bundle. If you override this method, make sure you call the parent implementation first.
public init ( )

registerClientEvents() 보호된 메소드

Registers JS event handlers that are listed in [[clientEvents]].
부터: 2.0.2
protected registerClientEvents ( )

registerPlugin() 보호된 메소드

Registers a specific Bootstrap plugin and the related events
protected registerPlugin ( string $name )
$name string the name of the Bootstrap plugin

프로퍼티 상세

$clientEvents 공개적으로 프로퍼티

the event handlers for the underlying Bootstrap JS plugin. Please refer to the corresponding Bootstrap plugin Web page for possible events. For example, this page shows how to use the "Modal" plugin and the supported events (e.g. "shown").
public $clientEvents

$clientOptions 공개적으로 프로퍼티

the options for the underlying Bootstrap JS plugin. Please refer to the corresponding Bootstrap plugin Web page for possible options. For example, this page shows how to use the "Modal" plugin and the supported options (e.g. "remote").
public $clientOptions