Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

could anyone please tell me how to hide post metadata from home page? I would like to have them displayed only in post page.

This is my website http://studyor.comuf.com and the theme was made with artisteer

Thanks!

Edit

Code copied/pasted from below:

    <?php get_header(); ?>
   <div class="art-layout-wrapper">
<div class="art-content-layout">
    <div class="art-content-layout-row">
        <div class="art-layout-cell art-content">
        <?php get_sidebar('top'); ?>
        <?php 
            if(have_posts()) {

                /* Display navigation to next/previous pages when applicable */
                if ( theme_get_option('theme_' . (theme_is_home() ? 'home_' : '') . 'top_posts_navigation' ) ) {
                    theme_page_navigation();
                }

                /* Start the Loop */ 
                while (have_posts()) {
                    the_post();
                    get_template_part('content', get_post_format());
                }

                /* Display navigation to next/previous pages when applicable */
                if (theme_get_option('theme_bottom_posts_navigation')) {
                     theme_page_navigation();
                }

            } else {

                 theme_404_content();

            } 
        ?>
        <?php get_sidebar('bottom'); ?>
          <div class="cleared"></div>
        </div>
        <div class="art-layout-cell art-sidebar1">
          <?php get_sidebar('default'); ?>
          <div class="cleared"></div>
        </div>
        <div class="art-layout-cell art-sidebar2">
          <?php get_sidebar('secondary'); ?>
          <div class="cleared"></div>
        </div>
    </div>
</div>
share|improve this question
3  
What have you tried already? Please add the code needed to understand your question. It should not rely on external resources. –  toscho Sep 17 '12 at 1:35

3 Answers 3

The problem could be in multiple locations, but it's probably in your index.php or loop.php file. Look for "Tagged" in the theme file, and compare to Template Heirarchy to figure out which page to delete the line from.

If you show your code snippet, we can tell you which exact line needs to go.

share|improve this answer

If you want to display content only on the single blog post page, use is_single() or is_singular( 'post' ):

<?php
if ( is_singular( 'post' ) ) {
    // This is a single blog post page;
    // do something
}
?>
share|improve this answer
    
Thank you Chip, as I said before, I'm not good with php, but the solution that you provide seem to hide everything in my homepage. All I wanted is to hide from homepage the post metadata (tags, category) and to have them displayed only in the post page –  user20512 Sep 17 '12 at 15:28
1  
Where/how did you use the is_singular() conditional wrapper? Without seeing your actual code, to know how you implemented it, it is impossible to answer. –  Chip Bennett Sep 17 '12 at 19:16

You need to add the conditional tag after the function which generates the entry meta. As you haven't pasted the code from the correct file which generates it, its impossible to provide the exact solution which includes the conditional tag in the correct position in the code.

You would add this conditional immediately after the function name:

if ( is_singular('post') ) 

Note: Theme specific custom coding questions not specifically related to WordPress are off topic here.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.