Skip to content
TJ Baker edited this page Nov 20, 2013 · 2 revisions

Tooltip

redCORE uses Twitter Bootstrap tooltip system.

To use tooltips in any component we will use this loader:

JHtml::_('rbootstrap.tooltip');

You can customise the tooltip with options. This is the standard function call:

public static function tooltip($selector = '.hasTip', $params = array())

By default it will use the selector ".hasTip" (is the same used in Joomla! core). If you want to use tooltips with other classes you can use:

JHtml::_('rbootstrap.tooltip', '.my-tooltip');

The tooltip script also supports other parameters. This are the options supported by bootstrap:

Tooltip options

This is a sample call with custom options that places the tooltips at the right side of the object:

JHtml::_('rbootstrap.tooltip', '.hasTip', array('placement' => 'right'));

Clone this wiki locally