ThemeShaper Forums » Thematic

change page title

(6 posts)
  • Started 11 years ago by roar123
  • Latest reply from scottdeto
  • This topic is resolved
  1. roar123

    I have my front page set to a static page. It shows the title of the page as the title for the front page, how would I change that? w/o messing up the other pages titles

    Posted 11 years ago #
  2. I just thought of a simple solution for this last night for the theme I'm working on. Copy page.php into your child theme with something like:

    If custom field alt title is true
    Use custom field value
    Use the plain old title

    Then, the plain old title gets sent to the link (and title bar, unless you're using All-In-One SEO) while the page spits out whatever you like.

    Posted 11 years ago #
  3. Like so …

        global $post;
        // Check for Alternate Title
        $alt_title = get_post_meta($post->ID, 'Alt Title', $single = true);
        if($alt_title !== '') {
            print '<h1 class="entry-title">' . $alt_title . "</h1>";
        } else {
        			<?php thematic_postheader(); ?>
    <?php } ?>
    Posted 11 years ago #
  4. roar123

    well I feel bad I forgot I could just use all in one seo and do it that way.

    also another thing I was trying to do was hide <?php thematic_postheader(); ?>
    on a certain page like /?page_id=2

    i know u could do it but dont know how to call it

    <!-- if pageid ==2 -->
           <?php thematic_postheader(); ?>
    Posted 11 years ago #
  5. scottdeto

    I'd like a solution for this as well. I'm not sure I understand Ian's "like so" suggestion. Is that code supposed to go in an empty page.php in child directory?

    Posted 10 years ago #
  6. scottdeto

    I'll answer my own: I was trying to hide the <h1>Home</h1> on my home static page. I wanted to keep the page title (not meta title) on all other pages.

    In child css:

    body.slug-home .entry-title{

    Posted 10 years ago #

RSS feed for this topic


You must log in to post.