• Resolved Vera Schafer

    (@vschafer)


    I followed the instructions from a previous similar topic which is now closed. I was able to remove date created and author from my page.php.
    However, the font of the text changed to the same as of the author and I couldn’t figure out how to change it back. I’m using the template “Layers”. Any help will be greatly appreciated.

Viewing 7 replies - 1 through 7 (of 7 total)
  • I think the page structure was changed.

    Did you only removed these 2 lines ?

    <div class=”date”><abbr class=”published updated” title=”<?php the_time(‘Y-m-d\TH:i:s\Z’); ?>”><?php the_time(‘F jS, Y’) ?></abbr></div>
    <span class=”vcard author”>by<span class=”fn”> <?php the_author() ?></span></span>

    Your page.php should be like this

    <?php get_header(); ?>
    <?php get_sidebar(); ?>
    
    <div id="main">
        <!--Begin main -->
    
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
        <div id="post-<?php the_ID(); ?>" class="xfolkentry">
    	<h2><a href="<?php the_permalink() ?>" class="taggedlink entry-title" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
    		<div class="description">
            <?php the_content('Read the rest of this entry &raquo;'); ?>
    <?php wp_link_pages(array('before' => '<p><strong>Pages:</strong> ', 'after' => '</p>', 'next_or_number' => 'number')); ?>
            </div><!-- End description -->
    		<?php if ('open' == $post->comment_status) : ?>
    
            <!--comments are open -->
            <p class="details"><a href="<?php comments_link(); ?>">Comments (<?php comments_number('0','1','%'); ?>)</a><?php edit_post_link('Edit', ' | ', ''); ?></p>
            <?php else: ?>
            <!--comments are closed -->
            <?php /*check to see if there are any comments*/
    
                if ($comments) : ?>
                <p class="details"><a href="<?php comments_link(); ?>">Comments (<?php comments_number('0','1','%'); ?>)</a><?php edit_post_link('Edit', ' | ', ''); ?></p>
                <?php else: /* Any detail should not be shown because no comments and comments are closed*/?>
                <!-- <p class="details"><a href="<?php comments_link(); ?>">Comments (<?php comments_number('0','1','%'); ?>)</a><?php edit_post_link('Edit', ' | ', ''); ?></p> -->
                <?php endif; ?>
            <?php endif; ?>
    
    <?php comments_template(); ?>
          </div><!-- div post-<?php the_ID(); ?> ends here -->
    <?php endwhile; else : ?>
    
    		<h1>Not Found</h1>
    		<p>We respect your curiosity! But, what you are looking is not present here. Don't be disappointed, keep the spirit spirits high, keep learning, keep finding! Curiosity is good, first step towards innovation.</p>
    
    	<?php endif; ?>
    
    </div><!--End main -->
    </div><!-- End center -->
    </div><!--End primary-->
    
    <?php get_footer(); ?>
    Thread Starter Vera Schafer

    (@vschafer)

    Thanks a billion!!!! I’ll try it now! You just saved my day!

    Thread Starter Vera Schafer

    (@vschafer)

    It worked like a charm and again thank you so much! Would you please be so kind and tell me just the portion of the code that should have been deleted, so that I can learn it for the future?

    It just about CSS.

    For example

    <div id=”author”>
    author name here
    </div>

    <div id=”content”>
    content here
    </div>

    There are 2 section author & content, developer will define in CSS file that section with id = author should use a bold font and section with id = “content” should use normal weight font.

    and the problem occur when you delete some line in the template, therefor the structure change. For example

    <div id=”author”>
    content here
    </div>

    Now the content is in “author” section, so it display as bold text.

    I think.

    Thread Starter Vera Schafer

    (@vschafer)

    Gotcha! I can see that I have a looooot to lean about PHP, CSS and stuff. But thanks to good samaritans on duty like you, I’ll be a pro soon! Tks again!

    You’re welcome ^^

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘How do I remove date created and author from my pages?’ is closed to new replies.