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. |
public static function popover($label, $title, $content, $htmlOptions = array())
{
$htmlOptions['rel'] = 'popover';
$htmlOptions['data-content'] = $content;
$htmlOptions['data-toggle'] = 'popover';
return self::tooltipPopover($label, '#', $title, $htmlOptions);
}
public function testPopover() { $I = $this->codeGuy; $html = TbHtml::popover('Link', 'Heading text', 'Content text', array('class' => 'link')); $a = $I->createNode($html, 'a[rel=popover]'); $I->seeNodeCssClass($a, 'link'); $I->seeNodeAttributes($a, array('title' => 'Heading text', 'data-content' => 'Content text', 'data-toggle' => 'popover', 'href' => '#')); $I->seeNodeText($a, 'Link'); }