Class X2StarRating
CStarRating displays a star rating control that can collect user rating input.
CStarRating is based on jQuery Star Rating Plugin. It displays a list of stars indicating the rating values. Users can toggle these stars to indicate their rating input. On the server side, when the rating input is submitted, the value can be retrieved in the same way as working with a normal HTML input. For example, using
$this->widget('CStarRating',array('name'=>'rating'));
we can retrieve the rating value via <span
class="php-var">$_POST</span>[<span
class="php-quote">'rating'</span>]
.
CStarRating allows customization of its appearance. It also supports empty rating as well as read-only rating.
- CComponent
- CBaseController
- CWidget
- CInputWidget
- CStarRating
- X2StarRating
Package: system\web\widgets
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 1.0
Located at x2engine/protected/components/X2StarRating.php
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 1.0
Located at x2engine/protected/components/X2StarRating.php
public
|
#
registerClientScript( string $id )
This method is Copyright (c) 2008-2014 by Yii Software LLC http://www.yiiframework.com/license/ |
getClientOptions(),
registerCssFile(),
renderStars(),
run()
|
hasModel(),
resolveNameID()
|
__construct(),
actions(),
getController(),
getId(),
getOwner(),
getViewFile(),
getViewPath(),
init(),
render(),
setId()
|
beginCache(),
beginClip(),
beginContent(),
beginWidget(),
createWidget(),
endCache(),
endClip(),
endContent(),
endWidget(),
renderFile(),
renderInternal(),
widget()
|
__call(),
__get(),
__isset(),
__set(),
__unset(),
asa(),
attachBehavior(),
attachBehaviors(),
attachEventHandler(),
canGetProperty(),
canSetProperty(),
detachBehavior(),
detachBehaviors(),
detachEventHandler(),
disableBehavior(),
disableBehaviors(),
enableBehavior(),
enableBehaviors(),
evaluateExpression(),
getEventHandlers(),
hasEvent(),
hasEventHandler(),
hasProperty(),
raiseEvent()
|
$allowEmpty,
$blur,
$callback,
$cssFile,
$focus,
$maxRating,
$minRating,
$ratingStepSize,
$readOnly,
$resetText,
$resetValue,
$starCount,
$starWidth,
$titles
|
$attribute,
$htmlOptions,
$model,
$name,
$value
|
$actionPrefix,
$skin
|
$controller,
$id,
$owner,
$viewPath
|