Browse Source

minor fixes

tags/2.0.0-beta
Antonio Ramirez 12 years ago
parent
commit
6c25c8fca9
  1. 11
      yii/bootstrap/TypeAhead.php

11
yii/bootstrap/TypeAhead.php

@ -12,11 +12,11 @@ use yii\helpers\Html;
use yii\widgets\ActiveForm;
/**
* Modal renders a modal window that can be toggled by clicking on a button.
* TypeAhead renders a typehead bootstrap javascript component.
*
* For example,
*
* ~~~php
* ```php
* echo TypeAhead::widget(array(
* 'form' => $form,
* 'model' => $model,
@ -25,18 +25,18 @@ use yii\widgets\ActiveForm;
* 'source' => array('USA', 'ESP'),
* ),
* ));
* ~~~
* ```
*
* The following example will use the name property instead
*
* ~~~php
* ```php
* echo TypeAhead::widget(array(
* 'name' => 'country',
* 'pluginOptions' => array(
* 'source' => array('USA', 'ESP'),
* ),
* ));
*
*```
*
* @see http://twitter.github.io/bootstrap/javascript.html#typeahead
* @author Antonio Ramirez <amigo.cobos@gmail.com>
@ -87,6 +87,7 @@ class TypeAhead extends Widget
* If [[TypeAhead::form]] is null not from an [[ActiveForm]] instance, then the field will be rendered according to
* the `name` key setting of [[TypeAhead::options]] array attribute.
* @return string the rendering result
* @throws InvalidParamException
*/
public function renderField()
{

Loading…
Cancel
Save