WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] How to remove the thumbnail on top of my post in Twenty Twelve theme (8 posts)

  1. Dong Suzuki
    Member
    Posted 1 year ago #

    I have done some research but I still cannot fix the problem. I have an unwanted thumbnail on top of my post. I am using twenty twelve theme. This is what my post looks like:
    http://dongyuesu.com/art/portaiture/

    The problem occurs after I changed my content.php to move the thumbnail next to the post titles and excerpts in my home page. This is what my homepage looks like:
    http://dongyuesu.com/art/

    In my child theme content.php, I have removed this line
    <?php the_post_thumbnail(); ?>
    under <header class="entry-header">. It helps to remove the unwanted thumbnail on the home page, but the unwanted thumbnails on the post pages are still there.

    Do I need to post my content.php? I do not know how to do that though.

    Thanks in advance.

    Don

  2. Jose Castaneda
    Member
    Posted 1 year ago #

    You will want to change the content-single as well.

  3. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    the unwanted thumbnails on the post pages are still there.

    this is because the single post uses the same content.php as the posts page;

    this is the code from the sinlge post:

    <!-- Adds the 300x300 thumbnail/featured image -->
            <div class="excerpt-thumb">
                <a href="http://dongyuesu.com/art/portaiture/" title="Permalink to (Portraiture) I Am Who I Think You Think I Am" rel="bookmark">
                <img width="300" height="200" src="http://dongyuesu.com/art/wp-content/uploads/2013/02/artlife-14-300x200.jpg" class="alignleft wp-post-image" alt="artlife-14" />            </a>
            </div>

    if you don't want that in single posts, you need to wrap your code into a conditional statement;
    example:

    <?php if( !is_single() ) : ?>
    YOUR CODE
    <?php endif; ?>
  4. Dong Suzuki
    Member
    Posted 1 year ago #

    <?php if( !is_single() ) : ?>
    YOUR CODE
    <?php endif; ?>

    Thanks so much for the prompt reply!! This code resolves the problem. Thanks so much!

    One more related question:
    In my category page, the thumbnail is on top of the post title. If I want it to look like my homepage, where the thumbnail is on the left next to the post title, what should I do?

    Here is what my category page looks like:
    http://dongyuesu.com/art/category/photography/

  5. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    you only removed the 'clear' for the post titles in the posts page;

    .blog .entry-title, .blog .entry-header .entry-meta { clear: none; }

    extend theat to archive pages as well;

    for example, add:

    .archive .entry-title, .archive .entry-header .entry-meta { clear: none; }

  6. Dong Suzuki
    Member
    Posted 1 year ago #

    Thanks again. I have just done what you said, by extending the { clear: none; } to include archive, but things aren't changed. Besides CSS, could there be somewhere else that I need to fix?

  7. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    Besides CSS, could there be somewhere else that I need to fix?

    always clear the browser cache after changes to the styles, if you want to see the results immediately.
    press 'ctrl f5' or 'reload' the web page a few times (or check your browser's instructions)

    btw:
    I see the thumbnails to the left of the content, in the category archive.

  8. Dong Suzuki
    Member
    Posted 1 year ago #

    Oh yes you are right. The category archive is now showing what I want. Problem solved!
    I did refresh my browser a few times but things remained the same though. Then I switched to another computer and I saw the change. You are right that I need to clear the cache; but many other changes do not require clearing cache. That was why I had doubt. Sorry for that.

    Thanks again Alchymyth. I saw you quite active in different treads helping people. I am very grateful to your help!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.