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.
Exemplo n.º 1
0
	<div class="page-header">
		<a name="images"></a>

		<h1>Images</small></h1>
	</div>

	<div class="bs-docs-example">
		<div class="row-fluid" style="text-align: center; width: 450px;">
			<div class="span4">
				<?php 
echo TbHtml::imageRounded('holder.js/140x140');
?>
			</div>
			<div class="span4">
				<?php 
echo TbHtml::imageCircle('holder.js/140x140');
?>
			</div>
			<div class="span4">
				<?php 
echo TbHtml::imagePolaroid('holder.js/140x140');
?>
			</div>
		</div>
	</div>

    <pre class="prettyprint linenums">
&lt;?php echo TbHtml::imageRounded('...'); ?>
&lt;?php echo TbHtml::imageCircle('...'); ?>
&lt;?php echo TbHtml::imagePolaroid('...'); ?></pre>
Exemplo n.º 2
0
 public function testImageCircle()
 {
     $I = $this->codeGuy;
     $html = TbHtml::imageCircle('image.png', 'Alternative text', array('class' => 'image'));
     $img = $I->createNode($html, 'img.img-circle');
     $I->seeNodeCssClass($img, 'image');
     $I->seeNodeAttributes($img, array('src' => 'image.png', 'alt' => 'Alternative text'));
 }