PHP Class TbHtml

Inheritance: extends CHtml
Show file Open project: crisu83/yiistrap Class Usage Examples

Public Properties

Property Type Description
$errorCss the CSS class for displaying error inputs
$errorSummaryCss the CSS class for displaying error summaries.
$iconVendor the icon vendor

Protected Properties

Property Type Description
$defaultFormControlWidthClass todo: remove this.
$defaultFormLabelWidthClass todo: remove this.

Public Methods

Method Description
abbr ( string $text, string $word, array $htmlOptions = [] ) : string Generates an abbreviation with a help text.
activeCheckBox ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a check box for a model attribute.
activeCheckBoxControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a check box for a model attribute.
activeCheckBoxList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string Generates a check box list for a model attribute.
activeCheckBoxListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string Generates a control group with a check box list for a model attribute.
activeControlGroup ( string $type, CModel $model, string $attribute, array $htmlOptions = [], array $data = [] ) : string Generates an active form row.
activeDateField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a date field input for a model attribute.
activeDateFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a date field for a model attribute.
activeDropDownList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string Generates a drop down list for a model attribute.
activeDropDownListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string Generates a control group with a drop down list for a model attribute.
activeEmailField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates an email field input for a model attribute.
activeEmailFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a email field for a model attribute.
activeFileField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a file field input for a model attribute.
activeFileFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a file field for a model attribute.
activeInlineCheckBoxList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string Generates an inline check box list for a model attribute.
activeInlineCheckBoxListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string Generates a control group with an inline check box list for a model attribute.
activeInlineRadioButtonList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string Generates an inline radio button list for a model attribute.
activeInlineRadioButtonListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string Generates a control group with an inline radio button list for a model attribute.
activeListBox ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string Generates a list box for a model attribute.
activeListBoxControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string Generates a control group with a list box for a model attribute.
activeNumberField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a number field input for a model attribute.
activeNumberFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a number field for a model attribute.
activePasswordField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a password field input for a model attribute.
activePasswordFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a password field for a model attribute.
activeRadioButton ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a radio button for a model attribute.
activeRadioButtonControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a radio button for a model attribute.
activeRadioButtonList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string Generates a radio button list for a model attribute.
activeRadioButtonListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string Generates a control group with a radio button list for a model attribute.
activeRangeField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a range field input for a model attribute.
activeRangeFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a range field for a model attribute.
activeSearchQueryControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a search field for a model attribute.
activeSearchQueryField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a search query input for a model attribute.
activeTextArea ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a text area input for a model attribute.
activeTextAreaControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a text area for a model attribute.
activeTextField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a text field input for a model attribute.
activeTextFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a text field for a model attribute.
activeUneditableField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates an uneditable input for a model attribute.
activeUneditableFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a uneditable field for a model attribute.
activeUrlField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates an url field input for a model attribute.
activeUrlFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a control group with a url field for a model attribute.
addCssClass ( mixed $className, array &$htmlOptions ) : array Appends new class names to the given options.
addCssStyle ( string $style, array &$htmlOptions ) : array Appends a CSS style string to the given options.
address ( $text, array $htmlOptions = [] ) : string Generates an address block.
ajaxButton ( string $label, mixed $url, array $ajaxOptions = [], array $htmlOptions = [] ) : string Generates a push button that can initiate AJAX requests.
ajaxLink ( string $text, mixed $url, array $ajaxOptions = [], array $htmlOptions = [] ) : string Generates a link that can initiate AJAX requests.
ajaxSubmitButton ( string $label, mixed $url, array $ajaxOptions = [], array $htmlOptions = [] ) : string Generates a push button that can submit the current form in POST method.
alert ( string $color, string $message, array $htmlOptions = [] ) : string Generates an alert.
animatedProgressBar ( integer $width, array $htmlOptions = [] ) : string Generates an animated progress bar.
b ( string $text, array $htmlOptions = [] ) : string Generates bold text.
badge ( string $label, array $htmlOptions = [] ) : string Generates a badge span.
beginFormTb ( string $layout = self::FORM_LAYOUT_VERTICAL, string $action = '', string $method = 'post', array $htmlOptions = [] ) : string Generates an open form tag.
blockAlert ( string $color, string $message, array $htmlOptions = [] ) : string Generates an alert block.
breadcrumbs ( array $links, array $htmlOptions = [] ) : string Generates a breadcrumb menu.
btn ( string $type, string $label, array $htmlOptions = [] ) : string Generates a button.
button ( string $label = 'Button', array $htmlOptions = [] ) : string Generates an button.
buttonDropdown ( string $label, array $items, array $htmlOptions = [] ) : string Generates a button with a dropdown menu.
buttonGroup ( array $buttons, array $htmlOptions = [] ) : string Generates a button group.
buttonToolbar ( array $groups, array $htmlOptions = [] ) : string Generates a button toolbar.
carousel ( array $items, array $htmlOptions = [] ) : string Generates an image carousel.
carouselIndicators ( string $target, integer $numSlides, array $htmlOptions = [] ) : string Generates an indicator for the carousel.
carouselItem ( string $content, string $label, string $caption, array $htmlOptions = [] ) : string Generates a carousel item.
carouselNextLink ( string $label, mixed $url = '#', array $htmlOptions = [] ) : string Generates a next link for the carousel.
carouselPrevLink ( string $label, mixed $url = '#', array $htmlOptions = [] ) : string Generates a previous link for the carousel.
checkBox ( string $name, boolean $checked = false, array $htmlOptions = [] ) : string Generates a check box.
checkBoxControlGroup ( string $name, boolean | string $checked = false, array $htmlOptions = [] ) : string Generates a control group with a check box.
checkBoxList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string Generates a check box list.
checkBoxListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string Generates a control group with a check box list.
closeButton ( string $label = self::CLOSE_TEXT, array $htmlOptions = [] ) : string Generates a close button.
closeLink ( string $label = self::CLOSE_TEXT, mixed $url = '#', array $htmlOptions = [] ) : string Generates a close link.
code ( string $code, array $htmlOptions = [] ) : string Generates inline code.
codeBlock ( string $code, array $htmlOptions = [] ) : string Generates a code block.
collapseLink ( string $label, string $target, array $htmlOptions = [] ) : string Generates a collapse link.
controlGroup ( string $type, string $name, string $value = '', array $htmlOptions = [], array $data = [] ) : string Generates a form group.
controls ( mixed $controls, array $htmlOptions = [] ) : string Generates form controls.
controlsRow ( mixed $controls, array $htmlOptions = [] ) : string Generates form controls row.
createActiveInput ( string $type, CModel $model, string $attribute, array $htmlOptions = [], array $data = [] ) : string Creates an active form input of the given type.
createInput ( string $type, string $name, string $value, array $htmlOptions = [], array $data = [] ) : string Creates a form input of the given type.
customActiveControlGroup ( string $input, CModel $model, string $attribute, array $htmlOptions = [] ) : string Generates a custom (pre-rendered) active form control group.
customControlGroup ( string $input, string $name, array $htmlOptions = [] ) : string Generates a custom (pre-rendered) form control group.
dateField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a date field input.
dateFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a file field.
dropDownList ( string $name, string $select, array $data, array $htmlOptions = [] ) : string Generates a drop down list.
dropDownListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string Generates a control group with a drop down list.
dropdownToggleButton ( string $label = '', array $htmlOptions = [] ) : string Generates a dropdown toggle button.
dropdownToggleLink ( string $label, array $htmlOptions = [] ) : string Generates a dropdown toggle link.
dropdownToggleMenuLink ( string $label, string $url = '#', array $htmlOptions = [], integer $depth ) : string Generates a dropdown toggle menu item.
em ( string $text, array $htmlOptions = [], string $tag = 'p' ) : string Generates an emphasized text.
emailField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates an email field input.
emailFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with an email field.
error ( CModel $model, string $attribute, array $htmlOptions = [] ) : string Displays the first validation error for a model attribute.
errorSummary ( mixed $model, string $header = null, string $footer = null, array $htmlOptions = [] ) : string Displays a summary of validation errors for one or several models.
fileField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a file field input.
fileFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a file field.
formActions ( mixed $actions, array $htmlOptions = [] ) : string Generates form actions div. This is no longer necessary in Bootstrap 3, but it is still useful to use for horizontal forms. When used with a horizontal form, it will appropriately align the actions below other form controls.
formTb ( string $layout = self::FORM_LAYOUT_VERTICAL, string $action = '', string $method = 'post', array $htmlOptions = [] ) : string Generates a form tag.
help ( string $text, array $htmlOptions = [] ) : string Generates a help text.
helpBlock ( string $text, array $htmlOptions = [] ) : string Generates a help block.
heroUnit ( string $heading, string $content, array $htmlOptions = [] ) : string Generates a jumbotron unit.
htmlButton ( string $label = 'Button', array $htmlOptions = [] ) : string Generates an image submit button.
i ( string $text, array $htmlOptions = [] ) : string Generates italic text.
icon ( string $icon, array $htmlOptions = [], string $tagName = 'span' ) : string Generates an icon.
image ( string $src, string $alt = '', array $htmlOptions = [] ) : string Generates an image tag.
imageButton ( string $src, array $htmlOptions = [] ) : string Generates an image submit button.
imageCircle ( string $src, string $alt = '', array $htmlOptions = [] ) : string Generates an image tag with circle.
imagePolaroid ( string $src, string $alt = '', array $htmlOptions = [] ) : string Generates an image tag within polaroid frame.
imageRounded ( string $src, string $alt = '', array $htmlOptions = [] ) : string Generates an image tag with rounded corners.
imageThumbnail ( string $src, string $alt = '', array $htmlOptions = [] ) : string Generates an image tag within thumbnail frame.
inlineCheckBoxList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string Generates an inline check box list.
inlineCheckBoxListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string Generates a control group with an inline check box list.
inlineRadioButtonList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string Generates an inline radio button list.
inlineRadioButtonListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string Generates a control group with an inline radio button list.
inputButton ( string $label, array $htmlOptions = [] ) : string Generates a form input push button.
inputSubmit ( string $label = 'Submit', array $htmlOptions = [] ) : string Generates a form input submit push button.
labelTb ( string $label, array $htmlOptions = [] ) : string Generates a label span.
lead ( string $text, array $htmlOptions = [] ) : string Generates a paragraph that stands out.
link ( string $text, mixed $url = '#', array $htmlOptions = [] ) : string Generates a hyperlink tag.
linkButton ( string $label = 'Submit', array $htmlOptions = [] ) : string Generates a link submit button.
listBox ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string Generates a list box.
listBoxControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string Generates a control group with a list box.
media ( string $image, string $heading, string $content, array $htmlOptions = [] ) : string Generates a single media object.
mediaList ( array $items, array $htmlOptions = [] ) : string Generates a list of media objects.
medias ( array $items, string $tag = 'div' ) : string Generates multiple media objects.
menu ( array $items, array $htmlOptions = [], integer $depth ) : string Generates a menu.
menuDivider ( array $htmlOptions = [] ) : string Generates a menu divider.
menuHeader ( string $label, array $htmlOptions = [] ) : string Generates a menu header.
menuLink ( string $label, array $url, array $htmlOptions = [] ) : string Generates a menu link.
modalBody ( string $content, array $htmlOptions = [] ) : string Generates a modal body.
modalFooter ( string $content, array $htmlOptions = [] ) : string Generates a modal footer.
modalHeader ( string $content, array $htmlOptions = [] ) : string Generates a modal header.
muted ( string $text, array $htmlOptions = [], string $tag = 'p' ) : string Generates a muted text block.
mutedSpan ( string $text, array $htmlOptions = [] ) : string Generates a muted span.
nav ( string $type, array $items, array $htmlOptions = [] ) : string Generates a navigation menu.
navList ( array $items, array $htmlOptions = [] ) : string Generates a list navigation.
navbar ( string $content, array $htmlOptions = [] ) : string Generates a navbar.
navbarBrandLink ( string $label, string $url, array $htmlOptions = [] ) : string Generates a brand link for the navbar.
navbarCollapseLink ( string $target, array $htmlOptions = [] ) : string Generates a collapse element.
navbarForm ( mixed $action, string $method = 'post', array $htmlOptions = [] ) : string Generates a navbar form.
navbarMenuDivider ( array $htmlOptions = [] ) : string Generates a menu divider for the navbar.
navbarSearchForm ( mixed $action, string $method = 'post', array $htmlOptions = [] ) : string Generates a navbar search form.
navbarText ( string $text, array $htmlOptions = [], string $tag = 'p' ) : string Generates a text for the navbar.
numberField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a number field input.
numberFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a number field.
openTag ( string $tag, array $htmlOptions = [] ) : string Generates an open HTML element.
pageHeader ( string $heading, string $subtext, array $htmlOptions = [] ) : string Generates a pager header.
pager ( array $links, array $htmlOptions = [] ) : string Generates a pager.
pagerLink ( string $label, mixed $url, array $htmlOptions = [] ) : string Generates a pager link.
pagination ( array $items, array $htmlOptions = [] ) : string Generates a pagination.
paginationLink ( string $label, mixed $url, array $htmlOptions = [] ) : string Generates a pagination link.
passwordField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a password field input.
passwordFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a password field.
pills ( array $items, array $htmlOptions = [] ) : string Generates a pills navigation.
popover ( string $label, string $title, string $content, array $htmlOptions = [] ) : string Generates a popover.
progressBar ( integer $width, array $htmlOptions = [] ) : string Generates a progress bar.
quote ( string $text, array $htmlOptions = [] ) : string Generates a quote.
radioButton ( string $name, boolean $checked = false, array $htmlOptions = [] ) : string Generates a radio button.
radioButtonControlGroup ( string $name, boolean | string $checked = false, array $htmlOptions = [] ) : string Generates a control group with a radio button.
radioButtonList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string Generates a radio button list.
radioButtonListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string Generates a control group with a radio button list.
rangeField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a range field input.
rangeFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a range field.
resetButton ( string $label = 'Reset', array $htmlOptions = [] ) : string Generates a reset button.
searchForm ( mixed $action, string $method = 'post', array $htmlOptions = [] ) : string Generates a search form.
searchQueryControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a search field.
searchQueryField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a search input.
small ( string $text, array $htmlOptions = [] ) : string Generates small text.
smallAbbr ( string $text, string $word, array $htmlOptions = [] ) : string Generates a small abbreviation with a help text.
splitButtonDropdown ( string $label, array $items, array $htmlOptions = [] ) : string Generates a button with a split dropdown menu.
stackedPills ( array $items, array $htmlOptions = [] ) : string Generates a stacked pills navigation.
stackedProgressBar ( array $bars, array $htmlOptions = [] ) : string Generates a stacked progress bar.
stackedTabs ( array $items, array $htmlOptions = [] ) : string Generates a stacked tab navigation.
statefulFormTb ( $layout = self::FORM_LAYOUT_VERTICAL, mixed $action = '', string $method = 'post', array $htmlOptions = [] ) : string Generates a stateful form tag.
stripedProgressBar ( integer $width, array $htmlOptions = [] ) : string Generates a striped progress bar.
submitButton ( string $label = 'Submit', array $htmlOptions = [] ) : string Generates a submit button.
tabbable ( string $type, array $tabs, array $htmlOptions = [] ) : string Generates a tabbable menu.
tabbablePills ( array $pills, array $htmlOptions = [] ) : string Generates a tabbable pills menu.
tabbableTabs ( array $tabs, array $htmlOptions = [] ) : string Generates a tabbable tabs menu.
tabs ( array $items, array $htmlOptions = [] ) : string Generates a tab navigation.
tag ( string $tag, array $htmlOptions = [], mixed $content = false, boolean $closeTag = true ) : string Generates an HTML element.
textArea ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a text area input.
textAreaControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a text area.
textField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a text field input.
textFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with a text field.
thumbnail ( string $content, array $htmlOptions = [] ) : string Generates a thumbnail.
thumbnailLink ( string $content, mixed $url = '#', array $htmlOptions = [] ) : string Generates a link thumbnail.
thumbnails ( array $thumbnails, array $htmlOptions = [] ) : string Generates a list of thumbnails.
tooltip ( string $label, mixed $url, string $content, array $htmlOptions = [] ) : string Generates a tooltip.
uneditableField ( string $value, array $htmlOptions = [] ) : string Generates an uneditable input.
uneditableFieldControlGroup ( string $value = '', array $htmlOptions = [] ) : string Generates a control group with an uneditable field.
urlField ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates an url field input.
urlFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string Generates a control group with an url field.
verticalButtonGroup ( array $buttons, array $htmlOptions = [] ) : string Generates a vertical button group.
well ( string $content, array $htmlOptions = [] ) : string Generates a well element.

Protected Methods

Method Description
activeTextInputField ( string $type, CModel $model, string $attribute, array $htmlOptions ) : string Generates an input HTML tag for a model attribute.
addColClass ( &$htmlOptions ) Adds the appropriate column class to the given options applicable. The available columns are 'xs', 'sm', 'md', 'lg' for extra small, small, medium, and large to be used for the appropriate screen sizes. It is also possible to prevent your columns from stacking on smaller devices by combining a small column with a larger column: $htmlOptions = array( 'xs' => 12, 'md' => 8, ) Both classes will be applied.
addPullClass ( array &$htmlOptions ) Adds the pull class to the given options is applicable.
addSpanClass ( array &$htmlOptions ) Adds the grid span class to the given options is applicable. BS3 no longer use span classes. During the BS3 transition, this will use the col-md-* CSS class.
addTextAlignClass ( array &$htmlOptions ) Adds the text align class to the given options if applicable.
bar ( integer $width, array $htmlOptions = [] ) : string Generates a progress bar.
btnDropdown ( string $type, string $label, array $items, array $htmlOptions ) : string Generates a button dropdown.
close ( string $tag, string $label, array $htmlOptions = [] ) : string Generates a close element.
createButton ( string $type, string $label, array $htmlOptions ) : string Creates a button the of given type.
createCheckBoxAndRadioButtonLabel ( string $label, string $input, array $htmlOptions ) : string Generates a label for a checkbox or radio input by wrapping the input.
dropdown ( array $items, array $htmlOptions = [] ) : string Generates a dropdown menu.
dropdownToggle ( string $type, string $label, array $htmlOptions ) : string Generates a dropdown toggle element.
getAddOnClasses ( array $htmlOptions ) : string Returns the add-on classes based on the given options.
getColClasses ( array $htmlOptions ) : string Returns the col-* classes
inputAddOn ( string | array $addOns, array $htmlOptions, string $position = 'prepend' ) : string Generates an add-on for an input field.
inputHelp ( string $help, array $htmlOptions ) : string Generates a help text for an input field.
menuDropdown ( string $label, string $url, array $items, array $htmlOptions, integer $depth ) : string Generates a menu dropdown.
normalizeCheckBoxAndRadio ( string $input ) : array Normalizes the inputs in the given string by splitting them up into an array.
normalizeInputOptions ( array $options ) : array Normalizes input options.
normalizeTabs ( array $tabs, array &$panes, integer $i ) : array Normalizes the tab configuration.
popColClasses ( string &$htmlOptions ) : string Returns the col-* classes and removes the classes from $htmlOptions['class']
switchColToOffset ( string $class ) : string Nearly identical to {@link switchOffsetCol()} except it forces the class to be returned as its offset counterpart. It is also safe to pass in a class that is already an offset and it will just re-return it. For example, passing in col-md-2 will return col-md-offset-2. Passing in col-md-offset-4 will still return col-md-offset-4.
switchOffsetCol ( string $class ) : string Switches the column class to and from the col width itself to its offset counterpart. For example, passing in col-md-2 would be switched to col-md-offset-2
switchOffsetToCol ( string $class ) : string Nearly identical to {@link switchOffsetCol()} except it forces teh class to be returned as its column (e.g. "span") width counterpart. It is also safe to pass in a class that is already the column width and it will re-return it. For example, passing in col-md-offset-2 will return col-md-2. Passing in col-md-4 will still return col-md-4.
textInputField ( string $type, string $name, string $value, array $htmlOptions ) : string Generates an input HTML tag.
tooltipPopover ( string $label, mixed $url, string $title, array $htmlOptions ) : string Generates a base tooltip.

Method Details

abbr() public static method

Generates an abbreviation with a help text.
public static abbr ( string $text, string $word, array $htmlOptions = [] ) : string
$text string the abbreviation.
$word string the word the abbreviation is for.
$htmlOptions array additional HTML attributes.
return string the generated abbreviation.

activeCheckBox() public static method

Generates a check box for a model attribute.
public static activeCheckBox ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated check box.

activeCheckBoxControlGroup() public static method

Generates a control group with a check box for a model attribute.
See also: self::activeControlGroup
public static activeCheckBoxControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeCheckBoxList() public static method

Generates a check box list for a model attribute.
public static activeCheckBoxList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array $data value-label pairs used to generate the check box list.
$htmlOptions array additional HTML attributes.
return string the generated list.

activeCheckBoxListControlGroup() public static method

Generates a control group with a check box list for a model attribute.
See also: self::activeControlGroup
public static activeCheckBoxListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeControlGroup() public static method

Generates an active form row.
public static activeControlGroup ( string $type, CModel $model, string $attribute, array $htmlOptions = [], array $data = [] ) : string
$type string the input type.
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
$data array data for multiple select inputs.
return string the generated control group.

activeDateField() public static method

Generates a date field input for a model attribute.
See also: self::activeTextInputField
public static activeDateField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activeDateFieldControlGroup() public static method

Generates a control group with a date field for a model attribute.
See also: self::activeControlGroup
public static activeDateFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeDropDownList() public static method

Generates a drop down list for a model attribute.
public static activeDropDownList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes
return string the generated drop down list.

activeDropDownListControlGroup() public static method

Generates a control group with a drop down list for a model attribute.
See also: self::activeControlGroup
public static activeDropDownListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeEmailField() public static method

Generates an email field input for a model attribute.
See also: self::activeTextInputField
public static activeEmailField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activeEmailFieldControlGroup() public static method

Generates a control group with a email field for a model attribute.
See also: self::activeControlGroup
public static activeEmailFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeFileField() public static method

Generates a file field input for a model attribute.
See also: CHtml::activeFileField
public static activeFileField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activeFileFieldControlGroup() public static method

Generates a control group with a file field for a model attribute.
See also: self::activeControlGroup
public static activeFileFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeInlineCheckBoxList() public static method

Generates an inline check box list for a model attribute.
public static activeInlineCheckBoxList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array $data value-label pairs used to generate the check box list.
$htmlOptions array additional HTML attributes.
return string the generated list.

activeInlineCheckBoxListControlGroup() public static method

Generates a control group with an inline check box list for a model attribute.
See also: self::activeControlGroup
public static activeInlineCheckBoxListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeInlineRadioButtonList() public static method

Generates an inline radio button list for a model attribute.
public static activeInlineRadioButtonList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array $data value-label pairs used to generate the radio button list.
$htmlOptions array additional HTML attributes.
return string the generated list.

activeInlineRadioButtonListControlGroup() public static method

Generates a control group with an inline radio button list for a model attribute.
See also: self::activeControlGroup
public static activeInlineRadioButtonListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeListBox() public static method

Generates a list box for a model attribute.
public static activeListBox ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated list box

activeListBoxControlGroup() public static method

Generates a control group with a list box for a model attribute.
See also: self::activeControlGroup
public static activeListBoxControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeNumberField() public static method

Generates a number field input for a model attribute.
See also: self::activeTextInputField
public static activeNumberField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activeNumberFieldControlGroup() public static method

Generates a control group with a number field for a model attribute.
See also: self::activeControlGroup
public static activeNumberFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activePasswordField() public static method

Generates a password field input for a model attribute.
See also: self::activeTextInputField
public static activePasswordField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activePasswordFieldControlGroup() public static method

Generates a control group with a password field for a model attribute.
See also: self::activeControlGroup
public static activePasswordFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeRadioButton() public static method

Generates a radio button for a model attribute.
public static activeRadioButton ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated radio button.

activeRadioButtonControlGroup() public static method

Generates a control group with a radio button for a model attribute.
See also: self::activeControlGroup
public static activeRadioButtonControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeRadioButtonList() public static method

Generates a radio button list for a model attribute.
public static activeRadioButtonList ( CModel $model, string $attribute, array $data, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array $data value-label pairs used to generate the radio button list.
$htmlOptions array additional HTML attributes.
return string the generated list.

activeRadioButtonListControlGroup() public static method

Generates a control group with a radio button list for a model attribute.
See also: self::activeControlGroup
public static activeRadioButtonListControlGroup ( CModel $model, string $attribute, array $data = [], array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeRangeField() public static method

Generates a range field input for a model attribute.
See also: self::activeTextInputField
public static activeRangeField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activeRangeFieldControlGroup() public static method

Generates a control group with a range field for a model attribute.
See also: self::activeControlGroup
public static activeRangeFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeSearchQueryControlGroup() public static method

Generates a control group with a search field for a model attribute.
See also: self::activeControlGroup
public static activeSearchQueryControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeSearchQueryField() public static method

Generates a search query input for a model attribute.
public static activeSearchQueryField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input.

activeTextArea() public static method

Generates a text area input for a model attribute.
public static activeTextArea ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated text area.

activeTextAreaControlGroup() public static method

Generates a control group with a text area for a model attribute.
See also: self::activeControlGroup
public static activeTextAreaControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeTextField() public static method

Generates a text field input for a model attribute.
See also: self::activeTextInputField
public static activeTextField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activeTextFieldControlGroup() public static method

Generates a control group with a text field for a model attribute.
See also: self::activeControlGroup
public static activeTextFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeTextInputField() protected static method

This method generates an input HTML tag based on the given input name and value.
protected static activeTextInputField ( string $type, CModel $model, string $attribute, array $htmlOptions ) : string
$type string the input type.
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input tag.

activeUneditableField() public static method

Generates an uneditable input for a model attribute.
public static activeUneditableField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input.

activeUneditableFieldControlGroup() public static method

Generates a control group with a uneditable field for a model attribute.
See also: self::activeControlGroup
public static activeUneditableFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

activeUrlField() public static method

Generates an url field input for a model attribute.
See also: self::activeTextInputField
public static activeUrlField ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated input field.

activeUrlFieldControlGroup() public static method

Generates a control group with a url field for a model attribute.
See also: self::activeControlGroup
public static activeUrlFieldControlGroup ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

addColClass() protected static method

Adds the appropriate column class to the given options applicable. The available columns are 'xs', 'sm', 'md', 'lg' for extra small, small, medium, and large to be used for the appropriate screen sizes. It is also possible to prevent your columns from stacking on smaller devices by combining a small column with a larger column: $htmlOptions = array( 'xs' => 12, 'md' => 8, ) Both classes will be applied.
protected static addColClass ( &$htmlOptions )
$htmlOptions

addCssClass() public static method

.
public static addCssClass ( mixed $className, array &$htmlOptions ) : array
$className mixed the class(es) to append.
$htmlOptions array the options.
return array the options.

addCssStyle() public static method

Appends a CSS style string to the given options.
public static addCssStyle ( string $style, array &$htmlOptions ) : array
$style string the CSS style string.
$htmlOptions array the options.
return array the options.

addPullClass() protected static method

Adds the pull class to the given options is applicable.
protected static addPullClass ( array &$htmlOptions )
$htmlOptions array the HTML attributes.

addSpanClass() protected static method

Adds the grid span class to the given options is applicable. BS3 no longer use span classes. During the BS3 transition, this will use the col-md-* CSS class.
Deprecation:
protected static addSpanClass ( array &$htmlOptions )
$htmlOptions array the HTML attributes.

addTextAlignClass() protected static method

Adds the text align class to the given options if applicable.
protected static addTextAlignClass ( array &$htmlOptions )
$htmlOptions array the HTML attributes.

address() public static method

Generates an address block.
public static address ( $text, array $htmlOptions = [] ) : string
$text
$htmlOptions array additional HTML attributes.
return string the generated block.

ajaxButton() public static method

Generates a push button that can initiate AJAX requests.
public static ajaxButton ( string $label, mixed $url, array $ajaxOptions = [], array $htmlOptions = [] ) : string
$label string the button label.
$url mixed the URL for the AJAX request.
$ajaxOptions array AJAX options.
$htmlOptions array additional HTML attributes.
return string the generated button.

ajaxSubmitButton() public static method

Generates a push button that can submit the current form in POST method.
public static ajaxSubmitButton ( string $label, mixed $url, array $ajaxOptions = [], array $htmlOptions = [] ) : string
$label string the button label
$url mixed the URL for the AJAX request.
$ajaxOptions array AJAX options.
$htmlOptions array additional HTML attributes.
return string the generated button.

alert() public static method

Generates an alert.
public static alert ( string $color, string $message, array $htmlOptions = [] ) : string
$color string the color of the alert.
$message string the message to display.
$htmlOptions array additional HTML options.
return string the generated alert.

animatedProgressBar() public static method

Generates an animated progress bar.
public static animatedProgressBar ( integer $width, array $htmlOptions = [] ) : string
$width integer the progress in percent.
$htmlOptions array additional HTML attributes.
return string the generated progress bar.

b() public static method

Generates bold text.
public static b ( string $text, array $htmlOptions = [] ) : string
$text string the text to style.
$htmlOptions array additional HTML attributes.
return string the generated text.

badge() public static method

Generates a badge span.
public static badge ( string $label, array $htmlOptions = [] ) : string
$label string the badge text.
$htmlOptions array additional HTML attributes.
return string the generated span.

bar() protected static method

Generates a progress bar.
protected static bar ( integer $width, array $htmlOptions = [] ) : string
$width integer the progress in percent.
$htmlOptions array additional HTML attributes.
return string the generated bar.

beginFormTb() public static method

Generates an open form tag.
public static beginFormTb ( string $layout = self::FORM_LAYOUT_VERTICAL, string $action = '', string $method = 'post', array $htmlOptions = [] ) : string
$layout string the form layout.
$action string the form action URL.
$method string form method (e.g. post, get).
$htmlOptions array additional HTML attributes.
return string the generated tag.

blockAlert() public static method

Generates an alert block.
public static blockAlert ( string $color, string $message, array $htmlOptions = [] ) : string
$color string the color of the alert.
$message string the message to display.
$htmlOptions array additional HTML options.
return string the generated alert.

breadcrumbs() public static method

Generates a breadcrumb menu.
public static breadcrumbs ( array $links, array $htmlOptions = [] ) : string
$links array the breadcrumb links.
$htmlOptions array additional HTML attributes.
return string the generated breadcrumb.

btn() public static method

Generates a button.
public static btn ( string $type, string $label, array $htmlOptions = [] ) : string
$type string the button type.
$label string the button label text.
$htmlOptions array additional HTML attributes.
return string the generated button.

btnDropdown() protected static method

Generates a button dropdown.
protected static btnDropdown ( string $type, string $label, array $items, array $htmlOptions ) : string
$type string the button type.
$label string the button label text.
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated button.

button() public static method

Generates an button.
public static button ( string $label = 'Button', array $htmlOptions = [] ) : string
$label string the button label text.
$htmlOptions array additional HTML attributes.
return string the generated button.

buttonDropdown() public static method

Generates a button with a dropdown menu.
public static buttonDropdown ( string $label, array $items, array $htmlOptions = [] ) : string
$label string the button label text.
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated button.

buttonGroup() public static method

Generates a button group.
public static buttonGroup ( array $buttons, array $htmlOptions = [] ) : string
$buttons array the button configurations.
$htmlOptions array additional HTML options.
return string the generated button group.

buttonToolbar() public static method

Generates a button toolbar.
public static buttonToolbar ( array $groups, array $htmlOptions = [] ) : string
$groups array the button group configurations.
$htmlOptions array additional HTML options.
return string the generated button toolbar.

carouselIndicators() public static method

Generates an indicator for the carousel.
public static carouselIndicators ( string $target, integer $numSlides, array $htmlOptions = [] ) : string
$target string the CSS selector for the target element.
$numSlides integer the number of slides.
$htmlOptions array additional HTML attributes.
return string the generated indicators.

carouselItem() public static method

Generates a carousel item.
public static carouselItem ( string $content, string $label, string $caption, array $htmlOptions = [] ) : string
$content string the content.
$label string the item label text.
$caption string the item caption text.
$htmlOptions array additional HTML attributes.
return string the generated item.

checkBox() public static method

Generates a check box.
public static checkBox ( string $name, boolean $checked = false, array $htmlOptions = [] ) : string
$name string the input name.
$checked boolean whether the check box is checked.
$htmlOptions array additional HTML attributes.
return string the generated check box.

checkBoxControlGroup() public static method

Generates a control group with a check box.
See also: self::controlGroup
public static checkBoxControlGroup ( string $name, boolean | string $checked = false, array $htmlOptions = [] ) : string
$name string the input name.
$checked boolean | string whether the check box is checked.
$htmlOptions array additional HTML attributes.
return string the generated control group.

checkBoxList() public static method

Generates a check box list.
public static checkBoxList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string
$name string name of the check box list.
$select mixed selection of the check boxes.
$data array $data value-label pairs used to generate the check box list.
$htmlOptions array additional HTML attributes.
return string the generated list.

checkBoxListControlGroup() public static method

Generates a control group with a check box list.
See also: self::controlGroup
public static checkBoxListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string
$name string the input name.
$select string the selected value.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

close() protected static method

Generates a close element.
protected static close ( string $tag, string $label, array $htmlOptions = [] ) : string
$tag string the tag name.
$label string the element label text.
$htmlOptions array additional HTML attributes.
return string the generated element.

closeButton() public static method

Generates a close button.
public static closeButton ( string $label = self::CLOSE_TEXT, array $htmlOptions = [] ) : string
$label string the button label text.
$htmlOptions array the HTML options for the button.
return string the generated button.

code() public static method

Generates inline code.
public static code ( string $code, array $htmlOptions = [] ) : string
$code string the code.
$htmlOptions array additional HTML attributes.
return string the generated code.

codeBlock() public static method

Generates a code block.
public static codeBlock ( string $code, array $htmlOptions = [] ) : string
$code string the code.
$htmlOptions array additional HTML attributes.
return string the generated block.

controlGroup() public static method

Generates a form group.
public static controlGroup ( string $type, string $name, string $value = '', array $htmlOptions = [], array $data = [] ) : string
$type string the input type.
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
$data array data for multiple select inputs.
return string the generated control group.

controls() public static method

Generates form controls.
public static controls ( mixed $controls, array $htmlOptions = [] ) : string
$controls mixed the controls.
$htmlOptions array additional HTML attributes.
return string the generated controls.

controlsRow() public static method

Generates form controls row.
Deprecation: BS3 only requires a div.row container for all inputs if you want a controls row
public static controlsRow ( mixed $controls, array $htmlOptions = [] ) : string
$controls mixed the controls.
$htmlOptions array additional HTML attributes.
return string the generated controls.

createActiveInput() public static method

Creates an active form input of the given type.
public static createActiveInput ( string $type, CModel $model, string $attribute, array $htmlOptions = [], array $data = [] ) : string
$type string the input type.
$model CModel the model instance.
$attribute string the attribute name.
$htmlOptions array additional HTML attributes.
$data array data for multiple select inputs.
return string the input.

createButton() protected static method

Creates a button the of given type.
protected static createButton ( string $type, string $label, array $htmlOptions ) : string
$type string the button type.
$label string the button label.
$htmlOptions array additional HTML attributes.
return string the button.

createCheckBoxAndRadioButtonLabel() protected static method

Generates a label for a checkbox or radio input by wrapping the input.
protected static createCheckBoxAndRadioButtonLabel ( string $label, string $input, array $htmlOptions ) : string
$label string the label text.
$input string the input.
$htmlOptions array additional HTML attributes.
return string the generated label.

createInput() public static method

Creates a form input of the given type.
public static createInput ( string $type, string $name, string $value, array $htmlOptions = [], array $data = [] ) : string
$type string the input type.
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
$data array data for multiple select inputs.
return string the input.

customActiveControlGroup() public static method

Generates a custom (pre-rendered) active form control group.
public static customActiveControlGroup ( string $input, CModel $model, string $attribute, array $htmlOptions = [] ) : string
$input string the rendered input.
$model CModel the data model.
$attribute string the attribute.
$htmlOptions array additional HTML attributes.
return string the generated control group.

customControlGroup() public static method

Generates a custom (pre-rendered) form control group.
public static customControlGroup ( string $input, string $name, array $htmlOptions = [] ) : string
$input string the rendered input.
$name string the input name.
$htmlOptions array additional HTML attributes.
return string the generated control group.

dateField() public static method

Generates a date field input.
See also: self::textInputField
public static dateField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

dateFieldControlGroup() public static method

Generates a control group with a file field.
See also: self::controlGroup
public static dateFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

dropDownList() public static method

Generates a drop down list.
public static dropDownList ( string $name, string $select, array $data, array $htmlOptions = [] ) : string
$name string the input name.
$select string the selected value.
$data array data for generating the list options (value=>display).
$htmlOptions array
return string the generated drop down list.

dropDownListControlGroup() public static method

Generates a control group with a drop down list.
See also: self::controlGroup
public static dropDownListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string
$name string the input name.
$select string the selected value.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

dropdown() protected static method

Generates a dropdown menu.
protected static dropdown ( array $items, array $htmlOptions = [] ) : string
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated menu.

dropdownToggle() protected static method

Generates a dropdown toggle element.
protected static dropdownToggle ( string $type, string $label, array $htmlOptions ) : string
$type string the type of dropdown.
$label string the element text.
$htmlOptions array additional HTML attributes.
return string the generated element.

dropdownToggleButton() public static method

Generates a dropdown toggle button.
public static dropdownToggleButton ( string $label = '', array $htmlOptions = [] ) : string
$label string the button label text.
$htmlOptions array additional HTML attributes.
return string the generated button.

em() public static method

Generates an emphasized text.
public static em ( string $text, array $htmlOptions = [], string $tag = 'p' ) : string
$text string the text to emphasize.
$htmlOptions array additional HTML attributes.
$tag string the HTML tag.
return string the generated text.

emailField() public static method

Generates an email field input.
See also: self::textInputField
public static emailField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

emailFieldControlGroup() public static method

Generates a control group with an email field.
See also: self::controlGroup
public static emailFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

error() public static method

Displays the first validation error for a model attribute.
public static error ( CModel $model, string $attribute, array $htmlOptions = [] ) : string
$model CModel the data model.
$attribute string the attribute name.
$htmlOptions array additional HTML attributes.
return string the rendered error. Empty if no errors are found.

errorSummary() public static method

Displays a summary of validation errors for one or several models.
public static errorSummary ( mixed $model, string $header = null, string $footer = null, array $htmlOptions = [] ) : string
$model mixed the models whose input errors are to be displayed.
$header string a piece of HTML code that appears in front of the errors.
$footer string a piece of HTML code that appears at the end of the errors.
$htmlOptions array additional HTML attributes to be rendered in the container div tag.
return string the error summary. Empty if no errors are found.

fileField() public static method

Generates a file field input.
See also: CHtml::fileField
public static fileField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

fileFieldControlGroup() public static method

Generates a control group with a file field.
See also: self::controlGroup
public static fileFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

formActions() public static method

Generates form actions div. This is no longer necessary in Bootstrap 3, but it is still useful to use for horizontal forms. When used with a horizontal form, it will appropriately align the actions below other form controls.
public static formActions ( mixed $actions, array $htmlOptions = [] ) : string
$actions mixed the actions.
$htmlOptions array additional HTML attributes.
return string the generated actions.

formTb() public static method

Generates a form tag.
public static formTb ( string $layout = self::FORM_LAYOUT_VERTICAL, string $action = '', string $method = 'post', array $htmlOptions = [] ) : string
$layout string the form layout.
$action string the form action URL.
$method string form method (e.g. post, get).
$htmlOptions array additional HTML attributes.
return string the generated tag.

getAddOnClasses() protected static method

Returns the add-on classes based on the given options.
protected static getAddOnClasses ( array $htmlOptions ) : string
$htmlOptions array the options.
return string the classes.

getColClasses() protected static method

Returns the col-* classes
protected static getColClasses ( array $htmlOptions ) : string
$htmlOptions array with "class" set
return string

help() public static method

Generates a help text.
public static help ( string $text, array $htmlOptions = [] ) : string
$text string the help text.
$htmlOptions array additional HTML attributes.
return string the generated text.

helpBlock() public static method

Generates a help block.
Deprecation:
public static helpBlock ( string $text, array $htmlOptions = [] ) : string
$text string the help text.
$htmlOptions array additional HTML attributes.
return string the generated block.

heroUnit() public static method

Generates a jumbotron unit.
public static heroUnit ( string $heading, string $content, array $htmlOptions = [] ) : string
$heading string the heading text.
$content string the content text.
$htmlOptions array additional HTML attributes.
return string the generated hero unit.

htmlButton() public static method

Generates an image submit button.
public static htmlButton ( string $label = 'Button', array $htmlOptions = [] ) : string
$label string
$htmlOptions array additional HTML attributes.
return string the generated button.

i() public static method

Generates italic text.
public static i ( string $text, array $htmlOptions = [] ) : string
$text string the text to style.
$htmlOptions array additional HTML attributes.
return string the generated text.

icon() public static method

Generates an icon.
public static icon ( string $icon, array $htmlOptions = [], string $tagName = 'span' ) : string
$icon string the icon type.
$htmlOptions array additional HTML attributes.
$tagName string the icon HTML tag.
return string the generated icon.

image() public static method

Generates an image tag.
public static image ( string $src, string $alt = '', array $htmlOptions = [] ) : string
$src string the image URL.
$alt string the alternative text display.
$htmlOptions array additional HTML attributes.
return string the generated image tag.

imageButton() public static method

Generates an image submit button.
public static imageButton ( string $src, array $htmlOptions = [] ) : string
$src string the image URL
$htmlOptions array additional HTML attributes.
return string the generated button.

imageCircle() public static method

Generates an image tag with circle.
public static imageCircle ( string $src, string $alt = '', array $htmlOptions = [] ) : string
$src string the image URL.
$alt string the alternative text display.
$htmlOptions array additional HTML attributes.
return string the generated image tag.

imagePolaroid() public static method

Generates an image tag within polaroid frame.
Deprecation: See {@link imageThumbnail()}
public static imagePolaroid ( string $src, string $alt = '', array $htmlOptions = [] ) : string
$src string the image URL.
$alt string the alternative text display.
$htmlOptions array additional HTML attributes.
return string the generated image tag.

imageRounded() public static method

Generates an image tag with rounded corners.
public static imageRounded ( string $src, string $alt = '', array $htmlOptions = [] ) : string
$src string the image URL.
$alt string the alternative text display.
$htmlOptions array additional HTML attributes.
return string the generated image tag.

imageThumbnail() public static method

Generates an image tag within thumbnail frame.
public static imageThumbnail ( string $src, string $alt = '', array $htmlOptions = [] ) : string
$src string the image URL.
$alt string the alternative text display.
$htmlOptions array additional HTML attributes.
return string the generated image tag.

inlineCheckBoxList() public static method

Generates an inline check box list.
public static inlineCheckBoxList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string
$name string name of the check box list.
$select mixed selection of the check boxes.
$data array $data value-label pairs used to generate the check box list.
$htmlOptions array additional HTML attributes.
return string the generated list.

inlineCheckBoxListControlGroup() public static method

Generates a control group with an inline check box list.
See also: self::controlGroup
public static inlineCheckBoxListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string
$name string the input name.
$select string the selected value.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

inlineRadioButtonList() public static method

Generates an inline radio button list.
public static inlineRadioButtonList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string
$name string name of the radio button list.
$select mixed selection of the radio buttons.
$data array $data value-label pairs used to generate the radio button list.
$htmlOptions array additional HTML attributes.
return string the generated list.

inlineRadioButtonListControlGroup() public static method

Generates a control group with an inline radio button list.
See also: self::controlGroup
public static inlineRadioButtonListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string
$name string the input name.
$select string the selected value.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

inputAddOn() protected static method

Generates an add-on for an input field.
protected static inputAddOn ( string | array $addOns, array $htmlOptions, string $position = 'prepend' ) : string
$addOns string | array the add-on.
$htmlOptions array additional HTML attributes.
$position string either 'prepend' or 'append'. Position is only important if you are passing multiple addons and it's a mixture of text/radio/checkboxes or buttons. The current styling needs buttons at the ends.
return string the generated add-on.

inputButton() public static method

Generates a form input push button.
public static inputButton ( string $label, array $htmlOptions = [] ) : string
$label string the button label
$htmlOptions array additional HTML attributes.
return string the generated button.

inputHelp() protected static method

Generates a help text for an input field.
protected static inputHelp ( string $help, array $htmlOptions ) : string
$help string the help text.
$htmlOptions array additional HTML attributes.
return string the generated help text.

inputSubmit() public static method

Generates a form input submit push button.
public static inputSubmit ( string $label = 'Submit', array $htmlOptions = [] ) : string
$label string the button label
$htmlOptions array additional HTML attributes.
return string the generated button.

labelTb() public static method

Generates a label span.
public static labelTb ( string $label, array $htmlOptions = [] ) : string
$label string the label text.
$htmlOptions array additional HTML attributes.
return string the generated span.

lead() public static method

Generates a paragraph that stands out.
public static lead ( string $text, array $htmlOptions = [] ) : string
$text string the lead text.
$htmlOptions array additional HTML attributes.
return string the generated paragraph.

linkButton() public static method

Generates a link submit button.
public static linkButton ( string $label = 'Submit', array $htmlOptions = [] ) : string
$label string the button label.
$htmlOptions array additional HTML attributes.
return string the generated button tag.

listBox() public static method

Generates a list box.
public static listBox ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string
$name string the input name.
$select mixed the selected value(s).
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated list box

listBoxControlGroup() public static method

Generates a control group with a list box.
See also: self::controlGroup
public static listBoxControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string
$name string the input name.
$select string the selected value.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

media() public static method

Generates a single media object.
public static media ( string $image, string $heading, string $content, array $htmlOptions = [] ) : string
$image string the image url.
$heading string the heading text.
$content string the content text.
$htmlOptions array additional HTML attributes.
return string the media object.

mediaList() public static method

Generates a list of media objects.
public static mediaList ( array $items, array $htmlOptions = [] ) : string
$items array item configurations.
$htmlOptions array additional HTML attributes.
return string generated list.

medias() public static method

Generates multiple media objects.
public static medias ( array $items, string $tag = 'div' ) : string
$items array item configurations.
$tag string the item tag name.
return string generated objects.

menu() public static method

Generates a menu.
public static menu ( array $items, array $htmlOptions = [], integer $depth ) : string
$items array the menu items.
$htmlOptions array additional HTML attributes.
$depth integer the current depth.
return string the generated menu.

menuDivider() public static method

Generates a menu divider.
public static menuDivider ( array $htmlOptions = [] ) : string
$htmlOptions array additional HTML attributes.
return string the generated menu item.

menuDropdown() protected static method

Generates a menu dropdown.
protected static menuDropdown ( string $label, string $url, array $items, array $htmlOptions, integer $depth ) : string
$label string the link label.
$url string the link URL.
$items array the menu configuration.
$htmlOptions array additional HTML attributes.
$depth integer the current depth.
return string the generated dropdown.

menuHeader() public static method

Generates a menu header.
public static menuHeader ( string $label, array $htmlOptions = [] ) : string
$label string the header text.
$htmlOptions array additional HTML options.
return string the generated header.

modalBody() public static method

Generates a modal body.
public static modalBody ( string $content, array $htmlOptions = [] ) : string
$content string the body content.
$htmlOptions array additional HTML attributes.
return string the generated body.

modalFooter() public static method

Generates a modal footer.
public static modalFooter ( string $content, array $htmlOptions = [] ) : string
$content string the footer content.
$htmlOptions array additional HTML attributes.
return string the generated footer.

modalHeader() public static method

Generates a modal header.
public static modalHeader ( string $content, array $htmlOptions = [] ) : string
$content string the header content.
$htmlOptions array additional HTML attributes.
return string the generated header.

muted() public static method

Generates a muted text block.
public static muted ( string $text, array $htmlOptions = [], string $tag = 'p' ) : string
$text string the text.
$htmlOptions array additional HTML attributes.
$tag string the HTML tag.
return string the generated text block.

mutedSpan() public static method

Generates a muted span.
public static mutedSpan ( string $text, array $htmlOptions = [] ) : string
$text string the text.
$htmlOptions array additional HTML attributes.
return string the generated span.

nav() public static method

Generates a navigation menu.
public static nav ( string $type, array $items, array $htmlOptions = [] ) : string
$type string the menu type.
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated menu.

navList() public static method

Generates a list navigation.
public static navList ( array $items, array $htmlOptions = [] ) : string
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated menu.

navbar() public static method

Generates a navbar.
public static navbar ( string $content, array $htmlOptions = [] ) : string
$content string the navbar content.
$htmlOptions array additional HTML attributes.
return string the generated navbar.

navbarForm() public static method

Generates a navbar form.
public static navbarForm ( mixed $action, string $method = 'post', array $htmlOptions = [] ) : string
$action mixed the form action URL.
$method string form method (e.g. post, get).
$htmlOptions array additional HTML attributes
return string the generated form.

navbarMenuDivider() public static method

Generates a menu divider for the navbar.
public static navbarMenuDivider ( array $htmlOptions = [] ) : string
$htmlOptions array additional HTML attributes.
return string the generated divider.

navbarSearchForm() public static method

Generates a navbar search form.
public static navbarSearchForm ( mixed $action, string $method = 'post', array $htmlOptions = [] ) : string
$action mixed the form action URL.
$method string form method (e.g. post, get).
$htmlOptions array additional HTML attributes
return string the generated form.

navbarText() public static method

Generates a text for the navbar.
public static navbarText ( string $text, array $htmlOptions = [], string $tag = 'p' ) : string
$text string the text.
$htmlOptions array additional HTML attributes.
$tag string the HTML tag.
return string the generated text block.

normalizeCheckBoxAndRadio() protected static method

Normalizes the inputs in the given string by splitting them up into an array.
protected static normalizeCheckBoxAndRadio ( string $input ) : array
$input string the inputs.
return array an array with the following structure: array($hidden, $input)

normalizeInputOptions() protected static method

Normalizes input options.
protected static normalizeInputOptions ( array $options ) : array
$options array the options.
return array the normalized options.

normalizeTabs() protected static method

Normalizes the tab configuration.
protected static normalizeTabs ( array $tabs, array &$panes, integer $i ) : array
$tabs array the tab configuration.
$panes array a reference to the panes array.
$i integer the running index.
return array the items.

numberField() public static method

Generates a number field input.
See also: self::textInputField
public static numberField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

numberFieldControlGroup() public static method

Generates a control group with a number field.
See also: self::textInputField
public static numberFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

openTag() public static method

Generates an open HTML element.
public static openTag ( string $tag, array $htmlOptions = [] ) : string
$tag string the tag name.
$htmlOptions array the element attributes.
return string the generated HTML element tag.

pageHeader() public static method

Generates a pager header.
public static pageHeader ( string $heading, string $subtext, array $htmlOptions = [] ) : string
$heading string the heading text.
$subtext string the subtext.
$htmlOptions array additional HTML attributes.
return string the generated pager header.

pager() public static method

Generates a pager.
public static pager ( array $links, array $htmlOptions = [] ) : string
$links array the pager buttons.
$htmlOptions array additional HTML attributes.
return string the generated pager.

pagination() public static method

Generates a pagination.
public static pagination ( array $items, array $htmlOptions = [] ) : string
$items array the pagination buttons.
$htmlOptions array additional HTML attributes.
return string the generated pagination.

passwordField() public static method

Generates a password field input.
See also: self::textInputField
public static passwordField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

passwordFieldControlGroup() public static method

Generates a control group with a password field.
See also: self::textInputField
public static passwordFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

pills() public static method

Generates a pills navigation.
public static pills ( array $items, array $htmlOptions = [] ) : string
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated menu.

popColClasses() protected static method

Returns the col-* classes and removes the classes from $htmlOptions['class']
protected static popColClasses ( string &$htmlOptions ) : string
$htmlOptions string with class set
return string

popover() public static method

Generates a popover.
public static popover ( string $label, string $title, string $content, array $htmlOptions = [] ) : string
$label string the popover link label text.
$title string the popover title text.
$content string the popover content text.
$htmlOptions array additional HTML attributes.
return string the generated popover.

progressBar() public static method

Generates a progress bar.
public static progressBar ( integer $width, array $htmlOptions = [] ) : string
$width integer the progress in percent.
$htmlOptions array additional HTML attributes.
return string the generated progress bar.

quote() public static method

Generates a quote.
public static quote ( string $text, array $htmlOptions = [] ) : string
$text string the quoted text.
$htmlOptions array additional HTML attributes.
return string the generated quote.

radioButton() public static method

Generates a radio button.
public static radioButton ( string $name, boolean $checked = false, array $htmlOptions = [] ) : string
$name string the input name.
$checked boolean whether the radio button is checked.
$htmlOptions array additional HTML attributes.
return string the generated radio button.

radioButtonControlGroup() public static method

Generates a control group with a radio button.
See also: self::controlGroup
public static radioButtonControlGroup ( string $name, boolean | string $checked = false, array $htmlOptions = [] ) : string
$name string the input name.
$checked boolean | string whether the radio button is checked.
$htmlOptions array additional HTML attributes.
return string the generated control group.

radioButtonList() public static method

Generates a radio button list.
public static radioButtonList ( string $name, mixed $select, array $data, array $htmlOptions = [] ) : string
$name string name of the radio button list.
$select mixed selection of the radio buttons.
$data array $data value-label pairs used to generate the radio button list.
$htmlOptions array additional HTML attributes.
return string the generated list.

radioButtonListControlGroup() public static method

Generates a control group with a radio button list.
See also: self::controlGroup
public static radioButtonListControlGroup ( string $name, string $select = '', array $data = [], array $htmlOptions = [] ) : string
$name string the input name.
$select string the selected value.
$data array data for generating the list options (value=>display).
$htmlOptions array additional HTML attributes.
return string the generated control group.

rangeField() public static method

Generates a range field input.
See also: self::textInputField
public static rangeField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

rangeFieldControlGroup() public static method

Generates a control group with a range field.
See also: self::controlGroup
public static rangeFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name
$value string the input value
$htmlOptions array additional HTML attributes.
return string the generated control group.

resetButton() public static method

Generates a reset button.
public static resetButton ( string $label = 'Reset', array $htmlOptions = [] ) : string
$label string the button label
$htmlOptions array additional HTML attributes.
return string the generated button.

searchForm() public static method

Generates a search form.
public static searchForm ( mixed $action, string $method = 'post', array $htmlOptions = [] ) : string
$action mixed the form action URL.
$method string form method (e.g. post, get).
$htmlOptions array additional HTML options.
return string the generated form.

searchQueryControlGroup() public static method

Generates a control group with a search field.
See also: self::controlGroup
public static searchQueryControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string
$htmlOptions array additional HTML attributes.
return string the generated control group.

searchQueryField() public static method

Generates a search input.
public static searchQueryField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input.

small() public static method

Generates small text.
public static small ( string $text, array $htmlOptions = [] ) : string
$text string the text to style.
$htmlOptions array additional HTML attributes.
return string the generated text.

smallAbbr() public static method

Generates a small abbreviation with a help text.
public static smallAbbr ( string $text, string $word, array $htmlOptions = [] ) : string
$text string the abbreviation.
$word string the word the abbreviation is for.
$htmlOptions array additional HTML attributes.
return string the generated abbreviation.

splitButtonDropdown() public static method

Generates a button with a split dropdown menu.
public static splitButtonDropdown ( string $label, array $items, array $htmlOptions = [] ) : string
$label string the button label text.
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated button.

stackedPills() public static method

Generates a stacked pills navigation.
public static stackedPills ( array $items, array $htmlOptions = [] ) : string
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated menu.

stackedProgressBar() public static method

Generates a stacked progress bar.
public static stackedProgressBar ( array $bars, array $htmlOptions = [] ) : string
$bars array the bar configurations.
$htmlOptions array additional HTML attributes.
return string the generated progress bar.

stackedTabs() public static method

Generates a stacked tab navigation.
Deprecation: Style does not exist in BS3
public static stackedTabs ( array $items, array $htmlOptions = [] ) : string
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated menu.

statefulFormTb() public static method

Generates a stateful form tag.
public static statefulFormTb ( $layout = self::FORM_LAYOUT_VERTICAL, mixed $action = '', string $method = 'post', array $htmlOptions = [] ) : string
$action mixed the form action URL.
$method string form method (e.g. post, get).
$htmlOptions array additional HTML attributes.
return string the generated form tag.

stripedProgressBar() public static method

Generates a striped progress bar.
public static stripedProgressBar ( integer $width, array $htmlOptions = [] ) : string
$width integer the progress in percent.
$htmlOptions array additional HTML attributes.
return string the generated progress bar.

submitButton() public static method

Generates a submit button.
public static submitButton ( string $label = 'Submit', array $htmlOptions = [] ) : string
$label string the button label
$htmlOptions array additional HTML attributes.
return string the generated button.

switchColToOffset() protected static method

Nearly identical to {@link switchOffsetCol()} except it forces the class to be returned as its offset counterpart. It is also safe to pass in a class that is already an offset and it will just re-return it. For example, passing in col-md-2 will return col-md-offset-2. Passing in col-md-offset-4 will still return col-md-offset-4.
protected static switchColToOffset ( string $class ) : string
$class string
return string

switchOffsetCol() protected static method

Switches the column class to and from the col width itself to its offset counterpart. For example, passing in col-md-2 would be switched to col-md-offset-2
protected static switchOffsetCol ( string $class ) : string
$class string
return string

switchOffsetToCol() protected static method

Nearly identical to {@link switchOffsetCol()} except it forces teh class to be returned as its column (e.g. "span") width counterpart. It is also safe to pass in a class that is already the column width and it will re-return it. For example, passing in col-md-offset-2 will return col-md-2. Passing in col-md-4 will still return col-md-4.
protected static switchOffsetToCol ( string $class ) : string
$class string
return string

tabbable() public static method

Generates a tabbable menu.
public static tabbable ( string $type, array $tabs, array $htmlOptions = [] ) : string
$type string the menu type.
$tabs array the tab configurations.
$htmlOptions array additional HTML attributes.
return string the generated menu.

tabbablePills() public static method

Generates a tabbable pills menu.
public static tabbablePills ( array $pills, array $htmlOptions = [] ) : string
$pills array the pills.
$htmlOptions array additional HTML attributes.
return string the generated menu.

tabbableTabs() public static method

Generates a tabbable tabs menu.
public static tabbableTabs ( array $tabs, array $htmlOptions = [] ) : string
$tabs array the tab configurations.
$htmlOptions array additional HTML attributes.
return string the generated menu.

tabs() public static method

Generates a tab navigation.
public static tabs ( array $items, array $htmlOptions = [] ) : string
$items array the menu items.
$htmlOptions array additional HTML attributes.
return string the generated menu.

tag() public static method

Generates an HTML element.
public static tag ( string $tag, array $htmlOptions = [], mixed $content = false, boolean $closeTag = true ) : string
$tag string the tag name.
$htmlOptions array the element attributes.
$content mixed the content to be enclosed between open and close element tags.
$closeTag boolean whether to generate the close tag.
return string the generated HTML element tag.

textArea() public static method

Generates a text area input.
public static textArea ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated text area.

textAreaControlGroup() public static method

Generates a control group with a text area.
See also: self::controlGroup
public static textAreaControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

textField() public static method

Generates a text field input.
See also: self::textInputField
public static textField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

textFieldControlGroup() public static method

Generates a control group with a text field.
See also: self::controlGroup
public static textFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

textInputField() protected static method

This method generates an input HTML tag based on the given input name and value.
protected static textInputField ( string $type, string $name, string $value, array $htmlOptions ) : string
$type string the input type.
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input tag.

thumbnail() public static method

Generates a thumbnail.
public static thumbnail ( string $content, array $htmlOptions = [] ) : string
$content string the thumbnail content.
$htmlOptions array additional HTML attributes.
return string the generated thumbnail.

thumbnails() public static method

Generates a list of thumbnails.
public static thumbnails ( array $thumbnails, array $htmlOptions = [] ) : string
$thumbnails array the list configuration.
$htmlOptions array additional HTML attributes.
return string the generated thumbnails.

tooltip() public static method

Generates a tooltip.
public static tooltip ( string $label, mixed $url, string $content, array $htmlOptions = [] ) : string
$label string the tooltip link label text.
$url mixed the link url.
$content string the tooltip content text.
$htmlOptions array additional HTML attributes.
return string the generated tooltip.

tooltipPopover() protected static method

Generates a base tooltip.
protected static tooltipPopover ( string $label, mixed $url, string $title, array $htmlOptions ) : string
$label string the tooltip link label text.
$url mixed the link url.
$title string the tooltip title text.
$htmlOptions array additional HTML attributes.
return string the generated tooltip.

uneditableField() public static method

Generates an uneditable input.
public static uneditableField ( string $value, array $htmlOptions = [] ) : string
$value string the value.
$htmlOptions array additional HTML attributes.
return string the generated input.

uneditableFieldControlGroup() public static method

Generates a control group with an uneditable field.
See also: self::controlGroup
public static uneditableFieldControlGroup ( string $value = '', array $htmlOptions = [] ) : string
$value string
$htmlOptions array additional HTML attributes.
return string the generated control group.

urlField() public static method

Generates an url field input.
See also: self::textInputField
public static urlField ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated input field.

urlFieldControlGroup() public static method

Generates a control group with an url field.
See also: self::controlGroup
public static urlFieldControlGroup ( string $name, string $value = '', array $htmlOptions = [] ) : string
$name string the input name.
$value string the input value.
$htmlOptions array additional HTML attributes.
return string the generated control group.

verticalButtonGroup() public static method

Generates a vertical button group.
public static verticalButtonGroup ( array $buttons, array $htmlOptions = [] ) : string
$buttons array the button configurations.
$htmlOptions array additional HTML options.
return string the generated button group.

well() public static method

Generates a well element.
public static well ( string $content, array $htmlOptions = [] ) : string
$content string the well content.
$htmlOptions array additional HTML attributes.
return string the generated well.

Property Details

$defaultFormControlWidthClass protected static property

todo: remove this.
protected static $defaultFormControlWidthClass

$defaultFormLabelWidthClass protected static property

todo: remove this.
protected static $defaultFormLabelWidthClass

$errorCss public static property

the CSS class for displaying error inputs
public static $errorCss

$errorSummaryCss public static property

the CSS class for displaying error summaries.
public static $errorSummaryCss

$iconVendor public static property

the icon vendor
public static $iconVendor