blogtitle changes the blog title in the page content header, but it doesn't change it in the HTML head, inside the <title>...</title> tags. As a result, the page content title says e.g. "Carey's updates", but the browser banner still says e.g. "carey's blog". Please compare the pink areas in the attached screenshot.

The problem is that although blogtitle_preprocess_page() sets $vars['title'], it doesn't set $vars['head_title']. The latter has already been set in template_preprocess_page() (in includes/theme.inc), which has already been called by the time blogtitle_preprocess_page() is run.

The attached patch fixes this problem. Please review - I took the code from the method of setting $head_title in template_preprocess_page(), but I don't know if e.g. strip_tags() has to be there.

Thanks,
Andrew.

Comments

Andrew Schulman’s picture

Actually, the patch here isn't needed if the one at http://drupal.org/node/528276 is accepted, since that one properly sets the page title, which then causes the HTML head title to be correctly set.

remi’s picture

Status: Needs review » Closed (duplicate)

I marked this issue as a duplicate of issue #528276: doesn't change the page and RSS feed titles.

letsnurture’s picture

Hi, folk

It might happen with you that you want to place the different html "title" than the "title" of the content.

Drupal gives "title" to set for each page but the problem of using this "title" is, drupal also set the same title for head section of . So when one is developing a website which is specifically SEO oriented then the problem comes to the picture.

So the solution is.................. just at next door.......................

Here is the good drupal module for those who want to display different html title than the content title.

http://drupal.org/project/page_title

Regards,
Web-Farmer
www.letsnurture.com