Changeset 13024 for trunk/wp-content/themes/twentyten/index.php
- Timestamp:
- 02/08/2010 05:59:08 PM (16 years ago)
- File:
-
- 1 edited
-
trunk/wp-content/themes/twentyten/index.php (modified) (10 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-content/themes/twentyten/index.php
r13012 r13024 1 1 <?php get_header(); ?> 2 3 <div id="container"> 2 3 <div id="container"> 4 4 <div id="content"> 5 5 6 6 <?php global $wp_query; $total_pages = $wp_query->max_num_pages; if ( $total_pages > 1 ) { ?> 7 7 <div id="nav-above" class="navigation"> … … 9 9 <div class="nav-next"><?php previous_posts_link(__( 'Newer posts <span class="meta-nav">→</span>', 'twentyten' )) ?></div> 10 10 </div><!-- #nav-above --> 11 <?php } ?> 12 13 <?php if ( have_posts()) : while (have_posts()) : the_post(); ?>11 <?php } ?> 12 13 <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> 14 14 <?php if ( in_category( 'Gallery' ) ) { ?> 15 15 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> … … 21 21 the_permalink(); ?>" title="<?php the_time('Y-m-d\TH:i:sO') ?>" rel="bookmark"><span class="entry-date"><?php the_time( get_option( 'date_format' ) ); ?></span></a> 22 22 <span class="meta-sep"> <?php _e('by ', 'twentyten'); ?> </span> 23 <span class="author vcard"><a class="url fn n" href="<?php echo get_author_posts_url( $authordata->ID, $authordata->user_nicename ); ?>" title="<?php printf( __( 'View all posts by %s', 'twentyten' ), $authordata->display_name ); ?>"><?php the_author(); ?></a></span> 23 <span class="author vcard"><a class="url fn n" href="<?php echo get_author_posts_url( $authordata->ID, $authordata->user_nicename ); ?>" title="<?php printf( __( 'View all posts by %s', 'twentyten' ), $authordata->display_name ); ?>"><?php the_author(); ?></a></span> 24 24 </div><!-- .entry-meta --> 25 25 26 26 <div class="entry-content"> 27 27 <div class="gallery-thumb"><a class="size-thumbnail" href="<?php permalink_link() ?>"><?php $hilite = $wpdb->get_var( "SELECT ID FROM $wpdb->posts WHERE post_parent = '$post->ID' AND post_type = 'attachment' LIMIT 1" ); echo wp_get_attachment_image( $hilite, 'thumbnail' );?></a></div> 28 29 <p><em> This gallery contains <a href="<?php the_permalink(); ?>" title="<?php printf( __('Permalink to %s', 'twentyten'), the_title_attribute('echo=0') ); ?>" rel="bookmark"><?php echo $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->posts WHERE post_parent = '$post->ID' AND post_type = 'attachment'" ); ?> photos</a>.</em></p>30 28 29 <p><em><?php printf( __('This gallery contains <a %1$s>%2$s photos</a>.', 'twentyten'), 'href="' . get_permalink() . '" title="' . sprintf( __('Permalink to %s', 'twentyten'), the_title_attribute('echo=0') ) . '" rel="bookmark"', $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->posts WHERE post_parent = '$post->ID' AND post_type = 'attachment'" )); ?></em></p> 30 31 31 <?php the_excerpt(''); ?> 32 32 </div><!-- .entry-content --> … … 39 39 <a href="<?php echo $category_link; ?>" title="<?php _e('View posts in the Gallery category', 'twentyten'); ?>"><?php _e('More Galleries', 'twentyten'); ?></a> 40 40 41 <span class="meta-sep"> | </span> 41 <span class="meta-sep"> | </span> 42 42 43 43 <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), __( '1 Comment', 'twentyten' ), __( '% Comments', 'twentyten' ) ) ?></span> … … 49 49 50 50 <?php } elseif ( in_category( 'asides' ) ) { ?> 51 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 52 <div class="entry-content"> 51 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 52 <div class="entry-content"> 53 53 <?php the_content( __( 'Continue reading <span class="meta-nav">→</span>', 'twentyten' ) ); ?> 54 54 </div><!-- .entry-content --> … … 60 60 <span class="meta-sep"> <?php _e('by ', 'twentyten'); ?> </span> 61 61 <span class="author vcard"><a class="url fn n" href="<?php echo get_author_posts_url( $authordata->ID, $authordata->user_nicename ); ?>" title="<?php printf( __( 'View all posts by %s', 'twentyten' ), $authordata->display_name ); ?>"><?php the_author(); ?></a></span> 62 <span class="meta-sep"> | </span> 62 <span class="meta-sep"> | </span> 63 63 <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), __( '1 Comment', 'twentyten' ), __( '% Comments', 'twentyten' ) ) ?></span> 64 64 <?php edit_post_link( __( 'Edit', 'twentyten' ), "<span class=\"meta-sep\">|</span>\n\t\t\t\t\t\t<span class=\"edit-link\">", "</span>\n\t\t\t\t\t\n" ) ?> 65 </div><!-- #entry-utility --> 65 </div><!-- #entry-utility --> 66 66 </div><!-- #post-<?php the_ID(); ?> --> 67 68 67 68 69 69 <?php } else { ?> 70 70 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 71 71 <h2 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( __('Permalink to %s', 'twentyten'), the_title_attribute('echo=0') ); ?>" rel="bookmark"><?php the_title(); ?></a></h2> 72 72 73 73 <div class="entry-meta"> 74 74 <span class="meta-prep meta-prep-author"><?php _e('Posted on ', 'twentyten'); ?></span> … … 76 76 the_permalink(); ?>" title="<?php the_time('Y-m-d\TH:i:sO') ?>" rel="bookmark"><span class="entry-date"><?php the_time( get_option( 'date_format' ) ); ?></span></a> 77 77 <span class="meta-sep"> <?php _e('by ', 'twentyten'); ?> </span> 78 <span class="author vcard"><a class="url fn n" href="<?php echo get_author_posts_url( $authordata->ID, $authordata->user_nicename ); ?>" title="<?php printf( __( 'View all posts by %s', 'twentyten' ), $authordata->display_name ); ?>"><?php the_author(); ?></a></span>78 <span class="author vcard"><a class="url fn n"2 href="<?php echo get_author_posts_url( $authordata->ID, $authordata->user_nicename ); ?>" title="<?php printf( __( 'View all posts by %s', 'twentyten' ), $authordata->display_name ); ?>"><?php the_author(); ?></a></span> 79 79 </div><!-- .entry-meta --> 80 81 <div class="entry-content"> 80 81 <div class="entry-content"> 82 82 <?php the_content( __( 'Continue reading <span class="meta-nav">→</span>', 'twentyten' ) ); ?> 83 83 <?php wp_link_pages('before=<div class="page-link">' . __( 'Pages:', 'twentyten' ) . '&after=</div>') ?> … … 90 90 <span class="comments-link"><?php comments_popup_link( __( 'Leave a comment', 'twentyten' ), __( '1 Comment', 'twentyten' ), __( '% Comments', 'twentyten' ) ) ?></span> 91 91 <?php edit_post_link( __( 'Edit', 'twentyten' ), "<span class=\"meta-sep\">|</span>\n\t\t\t\t\t\t<span class=\"edit-link\">", "</span>\n\t\t\t\t\t\n" ) ?> 92 </div><!-- #entry-utility --> 92 </div><!-- #entry-utility --> 93 93 </div><!-- #post-<?php the_ID(); ?> --> 94 95 <?php comments_template(); ?> 96 94 95 <?php comments_template(); ?> 96 97 97 <?php } ?> 98 98 <?php endwhile; ?> … … 103 103 <?php get_search_form(); ?> 104 104 </div> 105 <?php endif; ?> 105 <?php endif; ?> 106 106 107 107 <?php global $wp_query; $total_pages = $wp_query->max_num_pages; if ( $total_pages > 1 ) { ?> … … 110 110 <div class="nav-next"><?php previous_posts_link(__( 'Newer posts <span class="meta-nav">→</span>', 'twentyten' )) ?></div> 111 111 </div><!-- #nav-below --> 112 <?php } ?> 113 114 </div><!-- #content --> 112 <?php } ?> 113 114 </div><!-- #content --> 115 115 </div><!-- #container --> 116 117 <?php get_sidebar(); ?> 116 117 <?php get_sidebar(); ?> 118 118 <?php get_footer(); ?>
Note: See TracChangeset
for help on using the changeset viewer.