private function PathContext::setContextIdentity in Acquia Lift Connector 8.3
Same name and namespace in other branches
- 8.4 src/Service/Context/PathContext.php \Drupal\acquia_lift\Service\Context\PathContext::setContextIdentity()
Set Context Identity.
Parameters
string $identity: Identity.
string $identityType: Identity type.
2 calls to PathContext::setContextIdentity()
- PathContext::setContextIdentityByRequest in src/
Service/ Context/ PathContext.php - Set Path Context Identity by request stack's query parameters.
- PathContext::setContextIdentityByUser in src/
Service/ Context/ PathContext.php - Set Context Identity by User.
File
- src/
Service/ Context/ PathContext.php, line 182
Class
Namespace
Drupal\acquia_lift\Service\ContextCode
private function setContextIdentity($identity, $identityType) {
// Sanitize string and output.
$sanitized_identity = Html::escape($identity);
$sanitized_identity_type = Html::escape($identityType);
$this->htmlHeadContexts['identity:' . $sanitized_identity_type] = $sanitized_identity;
}