HELP: Remove ONLY Page Titles from Twenty Ten v1.4? (13 posts)

  1. Brandon Moner
    Posted 4 years ago #

    I'm using WordPress v3.4 and a Child-Theme based off of Twenty Ten v1.4

    To remove the page titles I did the recommended CSS entry...
    display: none;
    ...to make sure the page titles aren't showing.

    However this has the adverse effect of removing the titles of my posts on the blog page as well. Not what I wanted at all.

    How can I remeedy this? Is there an updated method that's known, as I've done some searching and can only find old methods that don't apply anymore.

  2. WPyogi
    Forum Moderator
    Posted 4 years ago #

    Change the CSS selector so it only targets the page titles. (If you need more specific help, you'll need to post a link to your site.)

  3. Brandon Moner
    Posted 4 years ago #


    As I posted above, the .entry-title CSS class selector did not work for what I needed.

    I can't post a link to the site because I'm building locally. This is the final step in my page completion, and it's holding me up.

    It's not a seriously customized theme and uses the default Twenty Ten v1.4 as a base. I just need to know how to remove the page titles without it affecting the titles of the blog posts.

  4. potentweb
    Posted 4 years ago #

    On the page.php file, add your own custom class to whatever is encapsulating the title. Then in the CSS file, add display:none to your custom class. Or even simpler, just remove the_title() from the page.php file.


  5. Brandon Moner
    Posted 4 years ago #

    This is the full, unaltered code from the newest Twenty Ten v1.4 theme. Please tell me where any of these arguments are located from within this file, because I'm not finding any:

    [Code moderated as per the Forum Rules. The maximum number of lines of code that you can post in these forums is ten lines. Please use the pastebin]

    I've been through the forums and Google and, so far, you guys are telling me the outdated information that obviously does not apply to version 1.4 of this theme. So either my page.php seems to not have this, or something in page.php has changed since WordPress release 3.1.x (which seems to be where I'm finding outdated information for) that has NOT been carried over to release 3.4.

  6. potentweb
    Posted 4 years ago #

    Open up the file loop-page.php


    <?php if ( is_front_page() ) { ?>
    						<h2 class="entry-title"><?php the_title(); ?></h2>
    					<?php } else { ?>
    						<h1 class="entry-title"><?php the_title(); ?></h1>
    					<?php } ?>
  7. Unless you want to lose your changes at the next theme update, make a child theme first.


    It's easy to do and will save you grief later on.

  8. potentweb
    Posted 4 years ago #

    @Jan Dembowski totally forgot about that. Thanks!

  9. Brandon Moner
    Posted 4 years ago #

    So...anyone at all? I mean is this something that just can't be done? I'm not understanding why I can't seem to get this done WITHOUT using a plug-in.

  10. Michael
    Forum Moderator
    Posted 4 years ago #

    this is a fundamental formatting question (unless you want to go the way with editing loop-page.php) which can be solved by utilizing the output of page specific css class(es) by the body_class() function of the theme.

    using a tool such as Firebug http://getfirebug.com/ would help to find this css class;


    .page .entry-title { display: none; }


  11. Brandon Moner
    Posted 4 years ago #


    Ok thank you...


    ...where is the .page class? I know I've been up all night, but I was looking for something like that and couldn't find it.

    I'd just like to know where in the CSS controlled this so i can study it more now.

  12. Michael
    Forum Moderator
    Posted 4 years ago #

    the .page class is one of the classes output by body_class() if the viewer is on a static page;

    this code is in line 55 of header.php of Twenty Ten:

    <body <?php body_class(); ?>>

    I posted the link to the Codex chapter of 'body_class()' already.

    there might already be a few styles using this .page class in style.css of your theme; but if they are not there already, you need to add them.

  13. Brandon Moner
    Posted 4 years ago #


    Thank you again so much! I would've been stuck on that forever lol.

    Uploading the site tonight. I'll be sure to show you how your efforts have helped me.

Topic Closed

This topic has been closed to new replies.

About this Topic