Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. FrontMatter.php

function FrontMatter::getContent

Retrieves the extracted source content.

Return value

string The extracted source content.

Throws

\Drupal\Component\FrontMatter\Exception\FrontMatterParseException

File

core/lib/Drupal/Component/FrontMatter/FrontMatter.php, line 172

Class

FrontMatter
Component for parsing front matter from a source.

Namespace

Drupal\Component\FrontMatter

Code

public function getContent() : string {
    return $this->parse()['content'];
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal