Overview

Packages

  • application
    • commands
    • components
      • actions
      • filters
      • leftWidget
      • permissions
      • sortableWidget
      • util
      • webupdater
      • x2flow
        • actions
        • triggers
      • X2GridView
      • X2Settings
    • controllers
    • models
      • embedded
    • modules
      • accounts
        • controllers
        • models
      • actions
        • controllers
        • models
      • calendar
        • controllers
        • models
      • charts
        • models
      • contacts
        • controllers
        • models
      • docs
        • components
        • controllers
        • models
      • groups
        • controllers
        • models
      • marketing
        • components
        • controllers
        • models
      • media
        • controllers
        • models
      • mobile
        • components
      • opportunities
        • controllers
        • models
      • products
        • controllers
        • models
      • quotes
        • controllers
        • models
      • services
        • controllers
        • models
      • template
        • models
      • users
        • controllers
        • models
      • workflow
        • controllers
        • models
      • x2Leads
        • controllers
        • models
  • Net
  • None
  • PHP
  • system
    • base
    • caching
      • dependencies
    • collections
    • console
    • db
      • ar
      • schema
        • cubrid
        • mssql
        • mysql
        • oci
        • pgsql
        • sqlite
    • i18n
      • gettext
    • logging
    • test
    • utils
    • validators
    • web
      • actions
      • auth
      • filters
      • form
      • helpers
      • renderers
      • services
      • widgets
        • captcha
        • pagers
  • Text
    • Highlighter
  • zii
    • behaviors
    • widgets
      • grid
      • jui

Classes

  • CJuiAccordion
  • CJuiAutoComplete
  • CJuiButton
  • CJuiDatePicker
  • CJuiDialog
  • CJuiDraggable
  • CJuiDroppable
  • CJuiInputWidget
  • CJuiProgressBar
  • CJuiResizable
  • CJuiSelectable
  • CJuiSlider
  • CJuiSliderInput
  • CJuiSortable
  • CJuiTabs
  • CJuiWidget
  • Overview
  • Package
  • Class
  • Tree

Class CJuiSliderInput

CJuiSliderInput displays a slider. It can be used in forms and post its value.

CJuiSlider encapsulates the JUI slider plugin.

To use this widget, you may insert the following code in a view:

$this->widget('zii.widgets.jui.CJuiSliderInput',array(
    'name'=>'rate',
    'value'=>37,
    // additional javascript options for the slider plugin
    'options'=>array(
        'min'=>10,
        'max'=>50,
    ),
    'htmlOptions'=>array(
        'style'=>'height:20px;',
    ),
));

The widget can also be used in range mode which uses 2 sliders to set a range. In this mode, CJuiInputWidget::$attribute and CJuiSliderInput::$maxAttribute will define the attribute names for the minimum and maximum range values, respectively. For example:

$this->widget('zii.widgets.jui.CJuiSliderInput',array(
    'model'=>$model,
    'attribute'=>'timeMin',
    'maxAttribute'=>'timeMax',
    // additional javascript options for the slider plugin
    'options'=>array(
        'range'=>true,
        'min'=>0,
        'max'=>24,
    ),
));

If you need to use the slider event, please change the event value for 'stop' or 'change'.

By configuring the CJuiWidget::$options property, you may specify the options that need to be passed to the JUI slider plugin. Please refer to the JUI Slider API documentation for possible options (name-value pairs) and JUI Slider page for general description and demo.

CComponent
Extended by CBaseController
Extended by CWidget
Extended by CJuiWidget
Extended by CJuiInputWidget
Extended by CJuiSliderInput
Package: zii\widgets\jui
Copyright: 2008-2013 Yii Software LLC
License: http://www.yiiframework.com/license/
Author: Sebastian Thierer <sebathi@gmail.com>
Since: 1.1
Located at x2engine/framework/zii/widgets/jui/CJuiSliderInput.php
Methods summary
public
# run( )

Run this widget. This method registers necessary javascript and renders the needed HTML code.

Run this widget. This method registers necessary javascript and renders the needed HTML code.

Overrides

CWidget::run()
Methods inherited from CJuiInputWidget
hasModel(), resolveNameID()
Methods inherited from CJuiWidget
getScriptFile(), init(), registerCoreScripts(), registerScriptFile(), resolvePackagePath(), setScriptFile()
Methods inherited from CWidget
__construct(), actions(), getController(), getId(), getOwner(), getViewFile(), getViewPath(), render(), setId()
Methods inherited from CBaseController
beginCache(), beginClip(), beginContent(), beginWidget(), createWidget(), endCache(), endClip(), endContent(), endWidget(), renderFile(), renderInternal(), widget()
Methods inherited from CComponent
__call(), __get(), __isset(), __set(), __unset(), asa(), attachBehavior(), attachBehaviors(), attachEventHandler(), canGetProperty(), canSetProperty(), detachBehavior(), detachBehaviors(), detachEventHandler(), disableBehavior(), disableBehaviors(), enableBehavior(), enableBehaviors(), evaluateExpression(), getEventHandlers(), hasEvent(), hasEventHandler(), hasProperty(), raiseEvent()
Properties summary
public string $tagName 'div'
#

the name of the container element that contains the slider. Defaults to 'div'.

the name of the container element that contains the slider. Defaults to 'div'.

public integer $value
#

determines the value of the slider, if there's only one handle. If there is more than one handle, determines the value of the first handle.

determines the value of the slider, if there's only one handle. If there is more than one handle, determines the value of the first handle.

public string $event 'slide'
#

the name of the event where the input will be attached to the slider. It can be 'slide', 'stop' or 'change'. If you want to use 'slide' event change $event property to 'change'.

the name of the event where the input will be attached to the slider. It can be 'slide', 'stop' or 'change'. If you want to use 'slide' event change $event property to 'change'.

public string $maxAttribute
#

name of attribute for max value if slider is used in range mode.

name of attribute for max value if slider is used in range mode.

public string $maxName
#

the input name to be used for max value attribute when using slider in range mode. This must be set in case CJuiInputWidget::$model isn't used.

the input name to be used for max value attribute when using slider in range mode. This must be set in case CJuiInputWidget::$model isn't used.

Since

1.1.14
public integer $maxValue
#

determines the max value of the slider, if there's two handles (range mode). Ignored if there's only one handle.

determines the max value of the slider, if there's two handles (range mode). Ignored if there's only one handle.

Since

1.1.14
public string $maxIdSuffix '_end'
#

the suffix to be appended to the ID of the max value input element when slider used in range mode.

the suffix to be appended to the ID of the max value input element when slider used in range mode.

Since

1.1.14
Properties inherited from CJuiInputWidget
$attribute, $model, $name
Properties inherited from CJuiWidget
$_scriptFile, $cssFile, $htmlOptions, $options, $scriptUrl, $theme, $themeUrl
Properties inherited from CWidget
$actionPrefix, $skin
Magic properties inherited from CWidget
$controller, $id, $owner, $viewPath
API documentation generated by ApiGen 2.8.0