Admin display for the block
@param string $content
@return string
971262
public function edit($content)
    {
        $dotName = str_replace(['[', ']'], ['.', ''], $this->_getInputHTMLKey());
        $submittedData = Request::input($dotName);
        return CmsBlockInput::make($this->_block->type, $this->_editViewData + [
                'label' => $this->_block->label,
                'name' => $this->_getInputHTMLKey(),
                'content' => $content,
                'submitted_data' => $submittedData ? $this->_defaultData($submittedData) : null,
                'note' => $this->_block->note,
                '_block' => $this->_block,
                '_blockType' => $this
            ]);
    }
1107319
public function display($content, $options = [])
    {
        $content = parent::display($content, $options);
        if (!empty($options['source'])) {
            return $content;
        }
        if (isset($options['meta']) &&  !isset($options['nl2br'])) {
            $options['nl2br'] = $options['meta'];
        }
        if ((isset($options['nl2br']) && $options['nl2br']) || !isset($options['nl2br'])) {
            $content = nl2br($content);
        }
        if (!empty($options['length'])) {
            $options['keep_tags'] = empty($options['keep_tags']) ? '' : $options['keep_tags']; //ie <br>,<p>
            $content = StringHelper::cutString(strip_tags($content, $options['keep_tags']), $options['length']);
            if ($options['keep_tags'] && $content) {
                $dom = new DOMDocument; // fix unclosed html tags
                $dom->loadHTML($content);
                $content = $dom->saveBodyHTML();
            }
        }
        return $content;
    }
161481
private function buildHeader(string $content): string
    {
        $header = "POST " . static::FLEEP_HOOK_URI . $this->token . " HTTP/1.1\r\n";
        $header .= "Host: " . static::FLEEP_HOST . "\r\n";
        $header .= "Content-Type: application/x-www-form-urlencoded\r\n";
        $header .= "Content-Length: " . strlen($content) . "\r\n";
        $header .= "\r\n";

        return $header;
    }
632440
public function show(ReadBlockInterface $block)
    {
        $contents = $this->getContents($block->getAttribute('contentSearch'));

        if (!is_null($contents)) {

            $parameters = array(
                'contents' => $contents,
                'class' => $block->getStyle(),
                'id' => $block->getId(),
                'characterNumber' => $block->getAttribute('characterNumber')
            );

            if ('' != $block->getAttribute('contentNodeId')) {
                $language = $this->currentSiteManager->getSiteLanguage();
                $siteId = $this->currentSiteManager->getSiteId();
                $node = $this->nodeRepository->findOnePublished($block->getAttribute('contentNodeId'), $language, $siteId);
                $parameters['contentNodeId'] = $node->getId();

                if (!$this->isGrantedNode($node)) {
                    unset($parameters['contentNodeId']);
                }
            }

            return $this->render('OpenOrchestraDisplayBundle:Block/ContentList:show.html.twig', $parameters);
        }

        throw new ContentNotFoundException();
    }
716009
private static function GetUpperContentRights(Content $content)
    {
        if ($content->GetPageContent())
        {
            $area = $content->GetPageContent()->GetArea();
            if ($area->GetLocked())
            {
                return null;
            }
            $pageRights = self::FindPageRights($content->GetPageContent()->GetPage());
            if ($pageRights)
            {
                return $pageRights->GetContentRights();
            }
        }
        else if ($content->GetLayoutContent())
        {
            $area = $content->GetLayoutContent()->GetArea();
            if ($area->GetLocked())
            {
                return null;
            }
            $layoutRights = $content->GetLayoutContent()->GetArea()->GetLayout()->GetUserGroupRights();
            if ($layoutRights)
            {
                return $layoutRights->GetContentRights();
            }
        }
        else if ($content->GetContainerContent())
        {
            $containerRights = $content->GetContainerContent()->GetContainer()->GetUserGroupRights();
            if ($containerRights)
            {
                return $containerRights->GetContentRights();
            }
        }
        return null;
    }
1023294
protected function notifyInfo($content) {
        $notification = NotificationFactory::newInfoNotification($content);
        return $this->notify(NotificationEvents::NOTIFICATION_INFO, $notification);
    }
1267626
public function processContent(string $content): string
    {
        return Strings::replace($content, self::HEADLINE_PATTERN, function (array $result): string {
            $titleWithoutTags = strip_tags($result['title']);
            $headlineId = Strings::webalize($titleWithoutTags);
            $titleWithLink = Strings::match($result['title'], self::LINK_PATTERN);
            $titleHasLink = is_array($titleWithLink) ? count($titleWithLink) > 0 : false;

            // Title contains <a> element
            if ($result['title'] !== $titleWithoutTags && $titleHasLink) {
                return sprintf(
                    '<h%s id="%s">%s</h%s>',
                    $result['level'],
                    $headlineId,
                    $result['title'],
                    $result['level']
                );
            }

            return sprintf(
                '<h%s id="%s"><a href="#%s" class="heading-anchor">%s</a></h%s>',
                $result['level'],
                $headlineId,
                $headlineId,
                $result['title'],
                $result['level']
            );
        });
    }
1241799
public static function staticClean($content): string
    {
        $cleaner = new self($content);
        $cleaner->clean();
        return $cleaner->retrieveXml();
    }
1057479
protected function _get_description( $content ) {
		preg_match( '/<meta +?property=["\']og:description["\'][^\/>]*? content=["\']([^"\']+?)["\'].*?\/?>/si', $content, $reg );
		if ( ! empty( $reg[1] ) ) {
			return $reg[1];
		}

		preg_match( '/<meta +?name=["\']description["\'][^\/>]*? content=["\']([^"\']+?)["\'].*?\/?>/si', $content, $reg );
		if ( ! empty( $reg[1] ) ) {
			return $reg[1];
		}
	}
669757
protected function _get_title( $content ) {
		preg_match( '/<meta +?property=["\']og:title["\'][^\/>]*? content=["\']([^"\']+?)["\'].*?\/?>/si', $content, $reg );
		if ( ! empty( $reg[1] ) ) {
			return $reg[1];
		}

		preg_match( '/<title>([^"\']+?)<\/title>/si', $content, $reg );
		if ( ! empty( $reg[1] ) ) {
			return $reg[1];
		}
	}
948594
public function render($content, $data = [])
    {
        if (!$content) {
            return '';
        }

        $html = $this->renderTwig($content, $data);

        $html = Markdown::parseSafe($html);

        return $html;
    }
186592
public function handle(?string $content = null): string
    {
        return trim((string) preg_replace('/\s+/', ' ', $this->ipsum));
    }
1266061
private function removeTitle($content)
    {
        $titles = [
            'Whoops, looks like something went wrong.',
            'Sorry, the page you are looking for could not be found.',
        ];

        foreach ($titles as $title) {
            $content = str_replace("<h1>{$title}</h1>", '', $content);
        }

        return $content;
    }
239975
protected function sanitizeContent($content) {
    $regex = '/^\n' . preg_quote($this->blockStart, '/') . ".*?" . preg_quote($this->blockEnd, '/') . '\n/sm';
    return preg_replace($regex, '', $content);
  }
580604
public function getControl($content = NULL)
	{
		$btn = Html::el('button', [
			'type' => 'button',
			'name' => $this->getHtmlName(),
		]);
		$btn->setHtml($content === NULL ? $this->caption : $content);
		$this->addBtnClass($btn);

		return $btn;
	}
151977
protected function string($content)
    {
        // Check if not is string ...
        if (false === is_string($content)) {
            // ... and make string of it.
            $content = var_export($content, true);
        }

        return $content;
    }
959930
public static function escapeAndMarkdown(?string $content): string
    {
        return $content ? C::getMarkdown()->text(Html::escape($content)) : (string) $content;
    }