WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] how to edit : Posted on September 28, 2010 by pauldiehl (5 posts)

  1. paul77
    Member
    Posted 4 years ago #

    twentyten theme :

    I don't use titles for my posts I just want the date to act as the title.

    Each post currently has this ex. "Posted on September 28, 2010 by pauldiehl"

    I would like to change it to just have ex. " September 28, 2010"

    I can't find in the PHP where to change this. From reading other posts it looks as if it would bee in loop.php but I can't seem to find it.

    Any help is much appreciated.
    Thanks,

    my site for reference http://dport7.com/

  2. Gisha James
    Member
    Posted 4 years ago #

    Edit index.php

    inside the loop you will see
    <?php the_author() ?> - which displays the author

  3. paul77
    Member
    Posted 4 years ago #

    I don't have that in index.php i have this

    <?php
    /**
    * The main template file.
    *
    * This is the most generic template file in a WordPress theme
    * and one of the two required files for a theme (the other being style.css).
    * It is used to display a page when nothing more specific matches a query.
    * E.g., it puts together the home page when no home.php file exists.
    * Learn more: http://codex.wordpress.org/Template_Hierarchy
    *
    * @package WordPress
    * @subpackage Twenty_Ten
    * @since Twenty Ten 1.0
    */

    get_header(); ?>

    <div id="container">
    <div id="content" role="main">

    <?php
    /* Run the loop to output the posts.
    * If you want to overload this in a child theme then include a file
    * called loop-index.php and that will be used instead.
    */
    get_template_part( 'loop', 'index' );
    ?>
    </div><!-- #content -->
    </div><!-- #container -->

    <?php get_sidebar(); ?>
    <?php get_footer(); ?>

    I have to apologize i'm very new to this.

    Thanks for you help

  4. Gisha James
    Member
    Posted 4 years ago #

    Are you using 2010 theme?

    If so, there is a function, twentyten_posted_on in functions.php.

    Replace it with the follwing.

    function twentyten_posted_on() {
    	printf( __( '<span class="%1$s">Posted on</span> %2$s', 'twentyten' ),
    		'meta-prep meta-prep-author',
    		sprintf( '<a href="%1$s" title="%2$s" rel="bookmark"><span class="entry-date">%3$s</span></a>',
    			get_permalink(),
    			esc_attr( get_the_time() ),
    			get_the_date()
    		)
    	);
    }
  5. paul77
    Member
    Posted 4 years ago #

    Thanks so much that worked great!!!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags