Skip to content

Instantly share code, notes, and snippets.

@pupi1985
Created November 6, 2016 15:45
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pupi1985/bb43d2213a8ebd242156f061f696800d to your computer and use it in GitHub Desktop.
Save pupi1985/bb43d2213a8ebd242156f061f696800d to your computer and use it in GitHub Desktop.
<?php
public function initialize()
{
parent::initialize();
$this->displayUserTitleInProfileSectionTitle();
}
private function displayUserTitleInProfileSectionTitle()
{
if ($this->template !== 'user') {
return;
}
if (!isset($this->content['form_activity']['fields']['title']['value'])) {
return;
}
$title = $this->content['form_activity']['fields']['title']['value'];
$this->content['title'] = $this->content['title'] . ' - ' . $title;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment