NodePreviewController::title

public NodePreviewController::title(EntityInterface $node_preview)

The _title_callback for the page that renders a single node in preview.

Parameters

\Drupal\Core\Entity\EntityInterface $node_preview: The current node.

Return value

string The page title.

File

core/modules/node/src/Controller/NodePreviewController.php, line 37

Class

NodePreviewController
Defines a controller to render a single node in preview.

Namespace

Drupal\node\Controller

Code

public function title(EntityInterface $node_preview) {
  return $this->entityManager->getTranslationFromContext($node_preview)->label();
}
doc_Drupal
2016-10-29 09:31:02
Comments
Leave a Comment

Please login to continue.