public function __construct($identifier, $src = "", $alt = "", $size = NULL) { $image = new HtmlImg("img-", $src, $alt); $image->setClass(""); parent::__construct($identifier, "div", "ui image", $image); if (isset($size)) { $this->setSize($size); } }
public function addImage($src = "", $alt = "", $size = NULL) { $image = new HtmlImg("img-", $src, $alt); if (isset($size)) { $image->setSize($size); } $this->content["image"] = $image; return $image; }
public function setImage($image) { $image = new HtmlImg("icon-" . $this->identifier, $image); $image->asAvatar(); $this->content["image"] = $image; }
/** * Adds an image * @param string $src * @param string $alt * @param boolean $before * @return \Ajax\semantic\html\elements\html5\HtmlImg */ public function addImage($src, $alt = "", $before = true) { $img = new HtmlImg("image-" . $this->identifier, $src, $alt); $img->setClass(""); $this->addContent($img, $before); return $img; }