public function getTextTag($renderApi, $unit, $moduleInfo, $content, $url) { $charLimit = $renderApi->getFormValue($unit, 'textCharLimit'); if (empty($content) && $renderApi->isEditMode()) { $i18n = new Translator($renderApi, $moduleInfo); $description = $i18n->translate('placeholder.pageDescription'); $content = $description . ' - Lorem ipsum dolor sit amet, eos ea soleat causae. Pro elitr eleifend prodesset ad, etiam volutpat no per, vim ea consul denique. Ullum lobortis evertitur ne vim, has audire incorrupte theophrastus at. Labitur vivendum electram pro et, sed movet accusata gloriatur at. Amet oratio repudiandae cu vis.'; } if ($charLimit > 0) { $content = $this->trimText($content, $charLimit); } // add space if link will get appended if ($renderApi->getFormValue($unit, 'enableTextLink')) { $content .= ' '; } $return = new HtmlTagBuilder('p', array('class' => 'teaserText'), array($content)); if ($renderApi->getFormValue($unit, 'enableTextLink')) { $return->append(new HtmlTagBuilder('a', array('href' => $url, 'class' => 'teaserTextLink'), array($renderApi->getFormValue($unit, 'textLinkLabel')))); } return $return; }