Ticket #12695: twentytendoc.4.demetris.diff
File twentytendoc.4.demetris.diff, 18.1 KB (added by , 15 years ago) |
---|
-
wp-content/themes/twentyten/404.php
1 <?php 2 /** 3 * The template for displaying 404 pages (Not Found) 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <?php get_header(); ?> 2 12 3 13 <div id="container"> -
wp-content/themes/twentyten/archive.php
1 <?php 2 /** 3 * Generic template for Archive pages 4 * 5 * Used to display archive-type pages if nothing more specific matches a query. 6 * E.g., puts together date-based pages if no date.php file exists. 7 * Learn more: http://codex.wordpress.org/Template_Hierarchy 8 * 9 * @since 0.7.0 10 * @package WordPress 11 * @subpackage 2010 12 */ 13 ?> 14 1 15 <?php get_header(); ?> 2 16 3 17 <div id="container"> -
wp-content/themes/twentyten/attachment.php
1 <?php 2 /** 3 * The template used to display Attachment-type pages 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <?php get_header(); ?> 2 12 3 13 <div id="container"> -
wp-content/themes/twentyten/author.php
1 <?php 2 /** 3 * The template used to display Author Archive pages 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <?php get_header(); ?> 2 12 3 13 <div id="container"> -
wp-content/themes/twentyten/category.php
1 <?php 2 /** 3 * The template used to display Category Archive pages 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <?php get_header(); ?> 2 12 3 13 <div id="container"> … … 13 23 * If you want to overload this in a child theme then include a file 14 24 * called loop-category.php and that will be used instead. 15 25 */ 16 26 get_template_part( 'loop', 'category' ); 17 27 ?> 18 28 19 29 </div><!-- #content --> -
wp-content/themes/twentyten/comments.php
1 <?php 2 /** 3 * The template used to display Comments 4 * 5 * The area of the page that contains both current comments 6 * and the comment form. The actual display of comments is 7 * handled by a callback to twentyten_comment which is 8 * located in the functions.php file 9 * 10 * @since 0.7.0 11 * @package WordPress 12 * @subpackage 2010 13 */ 14 ?> 15 1 16 <div id="comments"> 2 17 <?php if ( post_password_required() ) : ?> 3 18 <div class="nopassword"><?php _e( 'This post is password protected. Enter the password to view any comments.', 'twentyten' ); ?></div> -
wp-content/themes/twentyten/footer.php
1 <?php 2 /** 3 * The template used to display the footer 4 * 5 * Contains the closing of the id=main div and all content 6 * after. Calls sidebar-footer.php for bottom widgets 7 * 8 * @since 0.7.0 9 * @package WordPress 10 * @subpackage 2010 11 */ 12 ?> 13 1 14 </div><!-- #main --> 2 15 3 16 <div id="footer"> -
wp-content/themes/twentyten/functions.php
1 1 <?php 2 /** 3 * TwentyTen functions and definitions 4 * 5 * Sets up the theme and provides some helper functions used 6 * in other parts of the theme. All functions are pluggable 7 * 8 * @since 0.7.0 9 * @package WordPress 10 * @subpackage 2010 11 */ 2 12 3 // Set the content width based on the Theme CSS 13 // Set the content width based on the Theme CSS. Can be overriden 4 14 if ( ! isset( $content_width ) ) 5 15 $content_width = 640; 6 16 17 18 /** 19 * Set up defaults for our theme. 20 * 21 * Sets up theme defaults and tells wordpress that this is a 22 * theme that will take advantage of Post Thumbnails, Custom 23 * Background, Nav Menus and automatic feed links. To 24 * override any of the settings in a child theme, create your 25 * own twentyten_init function 26 * 27 * @uses add_theme_support() 28 * 29 * @since 0.7.0 30 * 31 * 32 */ 33 7 34 if ( ! function_exists( 'twentyten_init' ) ) : 8 35 function twentyten_init() { 9 36 // Your Changeable header business starts here … … 90 117 endif; 91 118 add_action( 'after_setup_theme', 'twentyten_init' ); 92 119 120 /** 121 * Callback to style the header image inside the admin 122 * 123 * 124 */ 125 93 126 if ( ! function_exists( 'twentyten_admin_header_style' ) ) : 94 127 function twentyten_admin_header_style() { 95 128 ?> … … 106 139 } 107 140 endif; 108 141 109 // Get the page number 142 143 /** 144 * Returns the page number currently being browsed 145 * 146 * Returns a vertical bar followed by page and the page 147 * number. Is pluggable 148 * 149 * @since 0.7.0 150 * @retun string 151 */ 152 153 110 154 if ( ! function_exists( 'twentyten_get_page_number' ) ) : 111 155 function twentyten_get_page_number() { 112 156 if ( get_query_var( 'paged' ) ) … … 114 158 } 115 159 endif; 116 160 117 // Echo the page number 161 /** 162 * Echos the page number being browsed 163 * 164 * @since 0.7.0 165 * @uses twentyten_get_page_number 166 * 167 */ 168 118 169 if ( ! function_exists( 'twentyten_the_page_number' ) ) : 119 170 function twentyten_the_page_number() { 120 171 echo twentyten_get_page_number(); 121 172 } 122 173 endif; 123 174 124 // Control excerpt length 175 /** 176 * Sets the excerpt length to 40 charachters. Is pluggable 177 * 178 * @since 0.7.0 179 * @return int 180 */ 181 125 182 if ( ! function_exists( 'twentyten_excerpt_length' ) ) : 126 183 function twentyten_excerpt_length( $length ) { 127 184 return 40; … … 130 187 add_filter( 'excerpt_length', 'twentyten_excerpt_length' ); 131 188 132 189 133 // Make a nice read more link on excerpts 190 /** 191 * Sets the read more link for excerpts to something pretty 192 * 193 * @since 0.7.0 194 * @return string 195 * 196 */ 134 197 if ( ! function_exists( 'twentyten_excerpt_more' ) ) : 135 198 function twentyten_excerpt_more( $more ) { 136 199 return ' … <a href="'. get_permalink() . '">' . __('Continue reading <span class="meta-nav">→</span>', 'twentyten') . '</a>'; … … 139 202 add_filter( 'excerpt_more', 'twentyten_excerpt_more' ); 140 203 141 204 142 // Template for comments and pingbacks 205 /** 206 * Template for comments and pingbacks 207 * 208 * Used as a callback by wp_list_comments for displaying the 209 * comments. Is pluggable 210 * 211 * @since 0.7.0 212 */ 143 213 if ( ! function_exists( 'twentyten_comment' ) ) : 144 214 function twentyten_comment( $comment, $args, $depth ) { 145 215 $GLOBALS ['comment'] = $comment; ?> … … 171 241 } 172 242 endif; 173 243 174 // Remove inline styles on gallery shortcode 244 /** 245 * Remove inline styles on gallery shortcode 246 * 247 * @since 0.7.0 248 * @return string 249 */ 175 250 if ( ! function_exists( 'twentyten_remove_gallery_css' ) ) : 176 251 function twentyten_remove_gallery_css( $css ) { 177 252 return preg_replace( "#<style type='text/css'>(.*?)</style>#s", '', $css ); … … 179 254 endif; 180 255 add_filter( 'gallery_style', 'twentyten_remove_gallery_css' ); 181 256 257 /** 258 * Returns the list of categories 259 * 260 * Returns the list of categories based on if we are or are 261 * not browsing a category archive page. 262 * 263 * @uses twentyten_term_list 264 * 265 * @since 0.7.0 266 * @return string 267 */ 268 182 269 if ( ! function_exists( 'twentyten_cat_list' ) ) : 183 270 function twentyten_cat_list() { 184 271 return twentyten_term_list( 'category', ', ', __( 'Posted in %s', 'twentyten' ), __( 'Also posted in %s', 'twentyten' ) ); 185 272 } 186 273 endif; 187 274 275 /** 276 * Returns the list of tags 277 * 278 * Returns the list of tags based on if we are or are not 279 * browsing a tag archive page 280 * 281 * @uses twentyten_term_list 282 * 283 * @since 0.7.0 284 * @return string 285 */ 188 286 if ( ! function_exists( 'twentyten_tag_list' ) ) : 189 287 function twentyten_tag_list() { 190 288 return twentyten_term_list( 'post_tag', ', ', __( 'Tagged %s', 'twentyten' ), __( 'Also tagged %s', 'twentyten' ) ); 191 289 } 192 290 endif; 193 291 292 /** 293 * Returns the list of taxonomy items in multiple ways 294 * 295 * Returns the list of taxonomy items differently based on 296 * if we are browsing a term archive page or a different 297 * type of page. If browsing a term archive page and the 298 * post has no other taxonomied terms, it returns empty 299 * 300 * @since 0.7.0 301 * @return string 302 */ 194 303 if ( ! function_exists( 'twentyten_term_list' ) ) : 195 304 function twentyten_term_list( $taxonomy, $glue = ', ', $text = '', $also_text = '' ) { 196 305 global $wp_query, $post; … … 219 328 } 220 329 endif; 221 330 222 // Register widgetized areas 331 /** 332 * Register widgetized areas 333 * 334 * @since 0.7.0 335 * @uses register_sidebar 336 */ 223 337 if ( ! function_exists( 'twentyten_widgets_init' ) ) : 224 338 function twentyten_widgets_init() { 225 339 // Area 1 -
wp-content/themes/twentyten/header.php
1 <?php 2 /** 3 * The Header for our theme. 4 * 5 * Displays all of the <head> section and everything up till <div id="main"> 6 * 7 * @since 0.7.0 8 * @package WordPress 9 * @subpackage 2010 10 */ 11 ?> 12 1 13 <!DOCTYPE html> 2 14 <html <?php language_attributes(); ?>> 3 15 <head> … … 3 15 <meta charset="<?php bloginfo( 'charset' ); ?>" /> 4 16 <title><?php 17 // Returns the title based on the type of page being viewed 5 18 if ( is_single() ) { 6 19 single_post_title(); echo ' | '; bloginfo( 'name' ); -
wp-content/themes/twentyten/index.php
1 <?php 2 3 /** 4 * The main template file 5 * 6 * This is the most generic template file in a WordPress theme 7 * and one of the two required files for a theme (the other being style.css). 8 * It is used to display a page when nothing more specific matches a query. 9 * E.g., it puts together the home page when no home.php file exists. 10 * Learn more: http://codex.wordpress.org/Template_Hierarchy 11 * 12 * @since 0.7.0 13 * @package WordPress 14 * @subpackage 2010 15 */ 16 17 ?> 18 1 19 <?php get_header(); ?> 2 20 3 21 <div id="container"> … … 14 32 </div><!-- #container --> 15 33 16 34 <?php get_sidebar(); ?> 17 <?php get_footer(); ?> 35 <?php get_footer(); ?> 36 No newline at end of file -
wp-content/themes/twentyten/loop.php
1 <?php 2 /** 3 * The loop that displays posts 4 * 5 * The loop displays the posts and the post content. See 6 * http://codex.wordpress.org/The_Loop to understand it and 7 * http://codex.wordpress.org/Template_Tags to understand 8 * the tags used in it. 9 * 10 * @since 0.7.0 11 * @package WordPress 12 * @subpackage 2010 13 */ 14 ?> 15 16 <?php /* Display navigation to next/previous pages when applicable */ ?> 1 17 <?php if ( $wp_query->max_num_pages > 1 ) : ?> 2 18 <div id="nav-above" class="navigation"> 3 19 <div class="nav-previous"><?php next_posts_link( __( '<span class="meta-nav">←</span> Older posts', 'twentyten' ) ); ?></div> … … 5 21 </div><!-- #nav-above --> 6 22 <?php endif; ?> 7 23 24 <?php /* If there are no posts to display, such as an empty archive page */ ?> 8 25 <?php if ( ! have_posts() ) : ?> 9 26 <div id="post-0" class="post error404 not-found"> 10 27 <h1 class="entry-title"><?php _e( 'Not Found', 'twentyten' ); ?></h1> … … 15 32 </div><!-- #post-0 --> 16 33 <?php endif; ?> 17 34 35 <?php /* Start the Loop */ ?> 18 36 <?php while ( have_posts() ) : the_post(); ?> 37 38 <?php /* How to Display posts in the Gallery Category */ ?> 19 39 <?php if ( in_category( 'Gallery' ) ) : ?> 20 40 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 21 41 <h2 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2> … … 62 82 </div><!-- #entry-utility --> 63 83 </div> 64 84 65 85 <?php /* How to display posts in the asides category */ ?> 66 86 <?php elseif ( in_category( 'asides' ) ) : ?> 67 87 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 68 88 <?php if ( is_archive() || is_search() ) : //Only display Excerpts for archives & search ?> … … 92 112 </div><!-- #entry-utility --> 93 113 </div><!-- #post-<?php the_ID(); ?> --> 94 114 95 115 <?php /* How to display all other posts */ ?> 96 116 <?php else : ?> 97 117 <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>> 98 118 <h2 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h2> … … 139 159 <?php endif; // if different categories queried ?> 140 160 <?php endwhile; ?> 141 161 162 <?php /* Display navigation to next/previous pages when applicable */ ?> 142 163 <?php if ( $wp_query->max_num_pages > 1 ) : ?> 143 164 <div id="nav-below" class="navigation"> 144 165 <div class="nav-previous"><?php next_posts_link( __( '<span class="meta-nav">←</span> Older posts', 'twentyten' ) ); ?></div> -
wp-content/themes/twentyten/onecolumn-page.php
1 2 1 <?php 3 /* 4 Template Name: One column, no sidebar 5 Description: A template with no sidebar 6 */ 7 get_header(); ?> 2 /** 3 * Template Name: One column, no sidebar 4 * 5 * A custom page template without sidebar. 6 * Selectable from a dropdown menu on the edit page screen. 7 * 8 * @since 0.7.0 9 * @package WordPress 10 * @subpackage 2010 11 */ 12 ?> 8 13 14 <?php get_header(); ?> 15 9 16 <div id="container" class="onecolumn"> 10 17 <div id="content"> 11 18 -
wp-content/themes/twentyten/page.php
1 <?php 2 /** 3 * The template used to display all pages 4 * 5 * This is the template that displays all pages by default. 6 * Please note that this is the wordpress construct of pages 7 * and that other 'pages' on your wordpress site will use a 8 * different template. 9 * 10 * @since 0.7.0 11 * @package WordPress 12 * @subpackage 2010 13 */ 14 ?> 15 1 16 <?php get_header(); ?> 2 17 3 18 <div id="container"> -
wp-content/themes/twentyten/search.php
1 <?php 2 /** 3 * The Search Results template 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <?php get_header(); ?> 2 12 3 13 <div id="container"> -
wp-content/themes/twentyten/searchform.php
1 <?php 2 /** 3 * The Search Form 4 * 5 * Optional file that allows displaying a custom search form 6 * when the get_search_form() template tag is used. 7 * 8 * @since 0.7.0 9 * @package WordPress 10 * @subpackage 2010 11 */ 12 ?> 13 1 14 <form id="searchform" name="searchform" method="get" action="<?php echo home_url(); ?>"> 2 15 <div> 3 16 <label for="s"><?php _e( 'Search', 'twentyten' ); ?></label> -
wp-content/themes/twentyten/sidebar-footer.php
1 1 <?php 2 /** 3 * The Footer widget areas 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 11 <?php 2 12 if ( 3 13 is_active_sidebar( 'first-footer-widget-area' ) || 4 14 is_active_sidebar( 'second-footer-widget-area' ) || -
wp-content/themes/twentyten/sidebar.php
1 <?php 2 /** 3 * The Sidebar containing the primary and secondary widget areas 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <div id="primary" class="widget-area"> 2 12 <ul class="xoxo"> 3 13 <?php if ( ! dynamic_sidebar( 'primary-widget-area' ) ) : // begin primary widget area ?> -
wp-content/themes/twentyten/single.php
1 <?php 2 /** 3 * The Template used to display all single posts 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <?php get_header(); ?> 2 12 3 13 <div id="container"> -
wp-content/themes/twentyten/tag.php
1 <?php 2 /** 3 * The template used to display Tag Archive pages 4 * 5 * @since 0.7.0 6 * @package WordPress 7 * @subpackage 2010 8 */ 9 ?> 10 1 11 <?php get_header(); ?> 2 12 3 13 <div id="container">