• I am trying to integrate a blog with a database such that in a particular set of categories, information is pulled from a separate database based on the post title.

    Everything works fine, except it would be *much* cleaner if I could have the template pages take on different behaviors for certain categories.

    The category-x.php doesn’t really seem to offer what I’m looking for.

    In general, everything is OK, except for the <title> and other meta tags from the header.

    How can I make these tags take on different sets of attributes for different categories?

    Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter bmaples

    (@bmaples)

    To be clearer, I’m trying to figure out how in php/Wordpress to do something like the following in the header:

    If category=1 then <title>ABC</title>

    else

    <title>XYZ</title>

    i think category-x.php is what you are looking for. but as a side thing you’ll also need a header-1.php which has a different title. include header-1 in category-1 and the normal header for the rest.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Change <title> depending on Category’ is closed to new replies.