function UncacheableFieldHandlerTrait::postRender
Same name in other branches
- 9 core/modules/views/src/Plugin/views/field/UncacheableFieldHandlerTrait.php \Drupal\views\Plugin\views\field\UncacheableFieldHandlerTrait::postRender()
- 10 core/modules/views/src/Plugin/views/field/UncacheableFieldHandlerTrait.php \Drupal\views\Plugin\views\field\UncacheableFieldHandlerTrait::postRender()
- 11.x core/modules/views/src/Plugin/views/field/UncacheableFieldHandlerTrait.php \Drupal\views\Plugin\views\field\UncacheableFieldHandlerTrait::postRender()
See also
\Drupal\views\Plugin\views\Field\FieldHandlerInterface::postRender()
File
-
core/
modules/ views/ src/ Plugin/ views/ field/ UncacheableFieldHandlerTrait.php, line 26
Class
- UncacheableFieldHandlerTrait
- Trait encapsulating the logic for uncacheable field handlers.
Namespace
Drupal\views\Plugin\views\fieldCode
public function postRender(ResultRow $row, $output) {
$placeholder = $this->getFieldTokenPlaceholder();
$value = $this->doRender($row);
$this->last_render = str_replace($placeholder, $value, $output);
return [
$placeholder => $value,
];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.