Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
AdditionalComment.php
Go to the documentation of this file.
1 <?php
7 
11 class AdditionalComment extends \Magento\Config\Block\System\Config\Form\Field
12 {
17  public function render(\Magento\Framework\Data\Form\Element\AbstractElement $element)
18  {
19  $html = '<div class="config-additional-comment-title">' . $element->getLabel() . '</div>';
20  $html .= '<div class="config-additional-comment-content">' . $element->getComment() . '</div>';
21  return $this->decorateRowHtml($element, $html);
22  }
23 
29  private function decorateRowHtml(\Magento\Framework\Data\Form\Element\AbstractElement $element, $html)
30  {
31  return sprintf(
32  '<tr id="row_%s"><td colspan="3"><div class="config-additional-comment">%s</div></td></tr>',
33  $element->getHtmlId(),
34  $html
35  );
36  }
37 }
render(\Magento\Framework\Data\Form\Element\AbstractElement $element)
$element
Definition: element.phtml:12