The following is for symfony 1.4 and is not necessarily backward compatible.
If you just want to completely change your title in symfony and you’re okay with wiping out whatever’s already there, it’s simple. Just use this in your action:
$this->getResponse()->setTitle('My New Title');
But what if you want to keep the first part of your app’s title and only change the rest? That’s also pretty easy. In apps/frontend/templates/layout.php, just change this
<?php include_title() ?>
to this:
<title>The Static Part of Your Title <?php echo $sf_response->getTitle() ?></title>
Now when you do this in your action
$this->getResponse()->setTitle('My New Title');
The “The Static Part of Your Title” will still be there and only the rest of it will have changed.