I spent a long while figuring out how to get custom page titles to work on taxonomy term pages.

* I have a Vocabulary 'Category' for which I set a default pattern: [term:name] | [site:name]
* Checked 'Show field'
* Visited the term form for a term in 'Category' - the term is 'teacher'
* Added custom page title 'mytitle'
* Viewed the term page
* Could not see 'mytitle' as page title. Instead it was: teacher | my site name

Try as I did, I could not figure out why my custom page title for that particular term would not appear.

I first thought it was because I was using a view to display the term page.

However on further introspection I found that hook_page_title_alter() was called only if the default pattern for the Vocabulary was: [current-page:page-title] | [site:name]

Only when token_replace on 'current-page:page-title' is run, would hook_page_title_alter() run, and correspondingly taxonomy_page_title_alter() would get called to set the title to the $term_title.

I would presume this is a bug rather than missing documentation. But if there are gaps in my understanding, please convert this to a documentation request.



delboard’s picture

Thanks girishmuraly, but in my case it didn't make any change.

To summarize, Views pages don't display a custom page title from a taxonomy term, that is set up using Page Title module.

Is there any solution for this?

konsul’s picture

just use an view header with global text area and the replacement pattern %1 .

xbrianx’s picture

I am having this same exact issue. I have a custom tag for a specific taxonomy term, but the global pattern is taking precedence

nirvanajyothi’s picture


marikomay’s picture

Same problem here. I tried konsul's suggestion to add view header with global text area and the replacement pattern %1, but still no go.

sayansk’s picture

Join us to the question!

nicholasThompson’s picture

Status: Active » Postponed (maintainer needs more info)

The token "[current-page:page-title]" will pick up the value associated with the Page Title field. The "[term:name]" token will use the term name, not the Page Title.

I'm not entirely clear what your issue is here... Can I clarify some points:

  • You have a taxonomy/term/123 style URL, yes?
  • Is taxonomy/term/% being handled by Taxonomy or Views?
  • Have you have enabled a custom pattern for the vocabulary (if so, what it it)? Have you enabled Show Field on the vocab?


girishmuraly’s picture

Status: Postponed (maintainer needs more info) » Active

Hey Nick, all the answers to your questions are in my initial bug report #0. Just to clarify:

  • You have a taxonomy/term/123 style URL, yes?
    • Yes
  • Is taxonomy/term/% being handled by Taxonomy or Views?
    • Views
  • Have you have enabled a custom pattern for the vocabulary (if so, what it it)? Have you enabled Show Field on the vocab?.
    • I did have a simple custom pattern, which was just the term name I believe (it was a long while ago). Show Field was on.
nicholasThompson’s picture

You're right - the information was, however I just wanted to make sure :)

If you use Views to handle the Taxonomy Term URL, then Taxonomy implementation will not match (see: http://drupalcode.org/project/page_title.git/blob/e9ab0ba62bc7d9e5e82b2c...).

The Menu Item for that path is no longer managed by Taxonomy and therefore the taxonomy named placeholder wont load the object.

Instead, Views takes over:

This means you need to control the Page Title pattern from within the View.

This is where is gets a bit convoluted (but I have just proved locally that it works).
1) In your View, you need to have a "Page (with Path Title)" display, not a Page.
2) The Term ID argument needs to be Overridden (not inherit from Default). Once this happens you get a Page Title fieldset at the top of the argument settings where you can define a Page Title Pattern for that argument. Unfortunately, we cannot access the entity page-title property as we have no idea what the context is at this point, without having a MASSIVE switch/case check to define which handlers define which entities. We can use %1 though...

We will need to look into how we can expand out $h in the modules/views.page_title.inc file. Currently we only know the ID...

FamousNerd’s picture

Firstly, I am on drupal 6 however, much of the above seems to apply.

My follow up question is regarding the page title pattern on the views-display.

1) I have a display on the view Page (with page title) for taxonomy/term/%
2) I have overridden the TermID for this display with the following:
Page Title Pattern: "%1 - page tittle pattern - [current-page-title]" (resulting in Term Name - page title pattern - Term Name)
Below that pattern is just a field called "Title:" set to %1
3) in Page Settings on the display I have Path: taxonomy/term/%, Menu: No menu, Page Title Pattern: none
4) In Page Title Module I have the following for Vocabulary - Product Categories: [current-page-title] | [page-title] (seems to be ignoredt... ideally used to append a suffix to all vocabulary titles)
5) in my Vocabulary term in content->taxonomy, expand the advanced section, Page title: "custom title" (ideally, used to define a specific title for this view)

In the end my desired result is to be able to set the Term's title in the Vocabulary Term AND
ideally append a suffix using the page title module such as | Products | [site-name]

So in summary, the category taxonomy view just shows the end result of Page Title Pattern and not any of the contributions from Page Title Module.

Does this bring to mind anything in terms of your described config above?


Edit: For those that are looking at an Ubercart product catalog view and looking for page titles, updating to page_title 6.x-2.6 will allow the page title to push from the taxonomy term into the taxonomy term which is handled by views. - that, I believe, was my issue.

manos_ws’s picture

I am using views to display the taxonomy page

I did what nicholasThompson in #9 and it is working as expected.

It only works with Page with Page title.

Does anyone knows why when I visit the taxonomy page I cant edit the view directly but I have to go to the admin/structure/views to edit it. ( when it is Page with page title, if it is just Page you can edit it directly from the taxonomy page)

adelka’s picture

not working for me...
I can only overide title in argument, but then I have the same title in H1 and

jenstechs’s picture

1) In your View, you need to have a "Page (with Path Title)" display, not a Page.

I'm lost here. Where is this?

HyperGlide’s picture

HyperGlide’s picture

crutch’s picture

I resolved for my specific config.

In my case, I'm using blocks in the secondary content wrapper (Adaptive Theme) above breadcrumbs for page titles. Also using panel node variants for node display. Have a page title view block for nodes but it wasn't working with taxonomy term pages and taxonomy lists.

- Using the View for taxonomy term view that comes with Views out of the box
- Categories (tags) are displayed on node display. In other words, the associated terms are being displayed below the content when viewing the specific node. Not sure if this effects anything or if the method depends on this.

Taxonomy Title Block
1. Create a new independent View Block named Taxonomy Title
2. Add field Categories (tags) with plain text formatter
3. In this field under "Multiple field settings", Display 1 value starting from 0
4. Rewrite results %1 - I guess this is sort of the same method as suggested everywhere else but that alone didn't work for this case
5. At Contextual Filters add Content: Has taxonomy term ID
6. Provide default value = Taxonomy term ID from URL
7. Checkbox "Load default filter from term page"
8. Add block to Secondary Content wrapper.

for breadcrumb using Crumbs module.

coolhandlukek2’s picture


minus’s picture

#2 is the easiest way

View header

Works for me, i'm editing the default taxonomy term view in views.

knalstaaf’s picture

Issue summary: View changes

#2 works for me too, just don't forget to check "use token replacement" in that very dialog.