page

Drupal Logo

Drupal 6: Change Title On Blog Index Page In Drupal

11th May 2010 - 4 minutes read time

The title tag on the Blog module index page (found at /blog after the module is installed) is by default "Blogs | Sitename", which isn't editable in the backend of Drupal. I've been talking to other Drupal developers and reading forums about the best way to go about changing the title of the blog index page. Ideas ranged from editing or duplicating the blog module (which is bad practice) to installing the String Overrides to provide a quick translation of the string in the title.

These suggestions are either quite poor, or simply overkill for what should be a simple string replacement. There were two methods we decided upon that work quite well and are easy to implement.

1) The first involves creating a page-blog.tpl.php template file and adding a str_replace() function call to replace the word blog from the title of the page. This would look something like this: