Ticket #38375: 38375.diff
File 38375.diff, 33.0 KB (added by , 7 years ago) |
---|
-
src/wp-content/themes/twentyseventeen/archive.php
diff --git a/src/wp-content/themes/twentyseventeen/archive.php b/src/wp-content/themes/twentyseventeen/archive.php index 8aa139f..6623321 100644
a b get_header(); ?> 37 37 * If you want to override this in a child theme, then include a file 38 38 * called content-___.php (where ___ is the Post Format name) and that will be used instead. 39 39 */ 40 get_template_part( ' components/post/content', get_post_format() );40 get_template_part( 'template-parts/post/content', get_post_format() ); 41 41 42 42 endwhile; 43 43 … … get_header(); ?> 49 49 50 50 else : 51 51 52 get_template_part( ' components/post/content', 'none' );52 get_template_part( 'template-parts/post/content', 'none' ); 53 53 54 54 endif; ?> 55 55 -
deleted file src/wp-content/themes/twentyseventeen/components/footer/footer-widgets.php
diff --git a/src/wp-content/themes/twentyseventeen/components/footer/footer-widgets.php b/src/wp-content/themes/twentyseventeen/components/footer/footer-widgets.php deleted file mode 100644 index ed6bb59..0000000
+ - 1 <?php2 /**3 * Displays footer widgets if assigned4 *5 * @package WordPress6 * @subpackage Twenty_Seventeen7 * @since 1.08 * @version 1.09 */10 11 ?>12 13 <?php14 if ( is_active_sidebar( 'sidebar-2' ) ||15 is_active_sidebar( 'sidebar-3' ) ) :16 ?>17 18 <aside class="widget-area" role="complementary">19 <?php20 if ( is_active_sidebar( 'sidebar-2' ) ) { ?>21 <div class="widget-column footer-widget-1">22 <?php dynamic_sidebar( 'sidebar-2' ); ?>23 </div>24 <?php }25 if ( is_active_sidebar( 'sidebar-3' ) ) { ?>26 <div class="widget-column footer-widget-2">27 <?php dynamic_sidebar( 'sidebar-3' ); ?>28 </div>29 <?php } ?>30 </aside><!-- .widget-area -->31 32 <?php endif; ?> -
deleted file src/wp-content/themes/twentyseventeen/components/footer/site-info.php
diff --git a/src/wp-content/themes/twentyseventeen/components/footer/site-info.php b/src/wp-content/themes/twentyseventeen/components/footer/site-info.php deleted file mode 100644 index 8455dc4..0000000
+ - 1 <?php2 /**3 * Displays footer site info4 *5 * @package WordPress6 * @subpackage Twenty_Seventeen7 * @since 1.08 * @version 1.09 */10 11 ?>12 <div class="site-info">13 <a href="<?php echo esc_url( __( 'https://wordpress.org/', 'twentyseventeen' ) ); ?>"><?php printf( __( 'Proudly powered by %s', 'twentyseventeen' ), 'WordPress' ); ?></a>14 </div><!-- .site-info --> -
deleted file src/wp-content/themes/twentyseventeen/components/header/header-image.php
diff --git a/src/wp-content/themes/twentyseventeen/components/header/header-image.php b/src/wp-content/themes/twentyseventeen/components/header/header-image.php deleted file mode 100644 index 102456d..0000000
+ - 1 <?php2 /**3 * Displays header image4 *5 * @package WordPress6 * @subpackage Twenty_Seventeen7 * @since 1.08 * @version 1.09 */10 11 ?>12 <div class="custom-header">13 <?php14 $header_image = get_header_image();15 16 // Check if Custom Header image has been added.17 if ( ! empty( $header_image ) ) : ?>18 19 <div class="custom-header-image" style="background-image: url(<?php echo esc_url( $header_image ); ?>)"></div>20 <?php get_template_part( 'components/header/site', 'branding' ); ?>21 22 <?php else : ?>23 <?php // Otherwise, show a blank header. ?>24 <div class="custom-header-simple">25 <?php get_template_part( 'components/header/site', 'branding' ); ?>26 </div><!-- .custom-header-simple -->27 28 <?php endif; ?>29 30 </div><!-- .custom-header --> -
deleted file src/wp-content/themes/twentyseventeen/components/header/site-branding.php
diff --git a/src/wp-content/themes/twentyseventeen/components/header/site-branding.php b/src/wp-content/themes/twentyseventeen/components/header/site-branding.php deleted file mode 100644 index d588cfa..0000000
+ - 1 <?php2 /**3 * Displays header site branding4 *5 * @package WordPress6 * @subpackage Twenty_Seventeen7 * @since 1.08 * @version 1.09 */10 11 ?>12 <div class="site-branding">13 <div class="wrap">14 15 <?php the_custom_logo(); ?>16 17 <div class="site-branding-text">18 <?php if ( is_front_page() ) : ?>19 <h1 class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></h1>20 <?php else : ?>21 <p class="site-title"><a href="<?php echo esc_url( home_url( '/' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?></a></p>22 <?php endif; ?>23 24 <?php $description = get_bloginfo( 'description', 'display' );25 if ( $description || is_customize_preview() ) : ?>26 <p class="site-description"><?php echo $description; /* WPCS: xss ok. */ ?></p>27 <?php endif; ?>28 </div><!-- .site-branding-text -->29 30 </div><!-- .wrap -->31 </div><!-- .site-branding --> -
deleted file src/wp-content/themes/twentyseventeen/components/navigation/navigation-top.php
diff --git a/src/wp-content/themes/twentyseventeen/components/navigation/navigation-top.php b/src/wp-content/themes/twentyseventeen/components/navigation/navigation-top.php deleted file mode 100644 index f44342e..0000000
+ - 1 <?php2 /**3 * Displays top navigation4 *5 * @package WordPress6 * @subpackage Twenty_Seventeen7 * @since 1.08 * @version 1.09 */10 11 ?>12 <nav id="site-navigation" class="main-navigation" role="navigation" aria-label="<?php _e( 'Top Menu', 'twentyseventeen' ); ?>">13 <button class="menu-toggle" aria-controls="top-menu" aria-expanded="false"><?php echo twentyseventeen_get_svg( array( 'icon' => 'bars' ) ); echo twentyseventeen_get_svg( array( 'icon' => 'close' ) ); _e( 'Menu', 'twentyseventeen' ); ?></button>14 <?php wp_nav_menu( array(15 'theme_location' => 'top',16 'menu_id' => 'top-menu',17 ) ); ?>18 19 <?php if ( twentyseventeen_is_frontpage() || ( is_home() && is_front_page() ) ) : ?>20 <a href="#content" class="menu-scroll-down"><?php echo twentyseventeen_get_svg( array( 'icon' => 'next' ) ); ?><span class="screen-reader-text"><?php _e( 'Scroll Down', 'twentyseventeen' ); ?></span></a>21 <?php endif; ?>22 </nav><!-- #site-navigation --> -
deleted file src/wp-content/themes/twentyseventeen/components/page/content-front-page-panels.php
diff --git a/src/wp-content/themes/twentyseventeen/components/page/content-front-page-panels.php b/src/wp-content/themes/twentyseventeen/components/page/content-front-page-panels.php deleted file mode 100644 index aa45a2b..0000000
+ - 1 <?php2 /**3 * Template part for displaying pages on front page4 *5 * @package WordPress6 * @subpackage Twenty_Seventeen7 * @since 1.08 * @version 1.09 */10 11 global $twentyseventeencounter;12 13 ?>14 15 <article id="post-<?php the_ID(); ?>" <?php post_class( 'twentyseventeen-panel ' ); ?> >16 17 <span class="panel twentyseventeen-panel<?php echo esc_attr( $twentyseventeencounter ); ?>" id="panel<?php echo esc_attr( $twentyseventeencounter ); ?>">18 <span class="twentyseventeen-panel-title"><?php printf( __( 'Panel %1$s', 'twentyseventeen' ), esc_attr( $twentyseventeencounter ) ); ?></span>19 </span>20 21 <?php if ( has_post_thumbnail() ) :22 $thumbnail = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' );23 24 $post_thumbnail_id = get_post_thumbnail_id( $post->ID );25 26 $thumbnail_attributes = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' );27 28 // Calculate aspect ratio: h / w * 100%.29 $ratio = $thumbnail_attributes[2] / $thumbnail_attributes[1] * 100;30 ?>31 32 <div class="panel-image" style="background-image: url(<?php echo esc_url( $thumbnail[0] ); ?>);">33 <div class="panel-image-prop" style="padding-top: <?php echo esc_attr( $ratio ); ?>%"></div>34 </div><!-- .panel-image -->35 36 <?php endif; ?>37 38 <div class="panel-content">39 <div class="wrap">40 <header class="entry-header">41 <?php the_title( '<h2 class="entry-title">', '</h2>' ); ?>42 43 <?php twentyseventeen_edit_link( get_the_ID() ); ?>44 45 </header><!-- .entry-header -->46 47 <div class="entry-content">48 <?php49 /* translators: %s: Name of current post */50 the_content( sprintf(51 __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),52 get_the_title()53 ) );54 ?>55 </div><!-- .entry-content -->56 57 <?php58 // Show recent blog posts if is blog posts page (Note that get_option returns a string, so we're casting the result as an int).59 if ( get_the_ID() === (int) get_option( 'page_for_posts' ) ) : ?>60 61 <?php // Show four most recent posts.62 $recent_posts = new WP_Query( array(63 'posts_per_page' => 3,64 'post_status' => 'publish',65 'ignore_sticky_posts' => true,66 'no_found_rows' => true,67 ) );68 ?>69 70 <?php if ( $recent_posts->have_posts() ) : ?>71 72 <div class="recent-posts">73 74 <?php75 while ( $recent_posts->have_posts() ) : $recent_posts->the_post();76 get_template_part( 'components/post/content', 'excerpt' );77 endwhile;78 wp_reset_postdata();79 ?>80 </div><!-- .pique-recent-posts -->81 <?php endif; ?>82 <?php endif; ?>83 84 </div><!-- .wrap -->85 </div><!-- .panel-content -->86 87 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/page/content-front-page.php
diff --git a/src/wp-content/themes/twentyseventeen/components/page/content-front-page.php b/src/wp-content/themes/twentyseventeen/components/page/content-front-page.php deleted file mode 100644 index 38fa0f7..0000000
+ - 1 <?php2 /**3 * Displays content for front page4 *5 * @package WordPress6 * @subpackage Twenty_Seventeen7 * @since 1.08 * @version 1.09 */10 11 ?>12 <article id="post-<?php the_ID(); ?>" <?php post_class( 'twentyseventeen-panel ' ); ?> >13 14 <?php if ( has_post_thumbnail() ) :15 $thumbnail = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' );16 17 $post_thumbnail_id = get_post_thumbnail_id( $post->ID );18 19 $thumbnail_attributes = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'twentyseventeen-featured-image' );20 21 // Calculate aspect ratio: h / w * 100%.22 $ratio = $thumbnail_attributes[2] / $thumbnail_attributes[1] * 100;23 ?>24 25 <div class="panel-image" style="background-image: url(<?php echo esc_url( $thumbnail[0] ); ?>);">26 <div class="panel-image-prop" style="padding-top: <?php echo esc_attr( $ratio ); ?>%"></div>27 </div><!-- .panel-image -->28 29 <?php endif; ?>30 31 <div class="panel-content">32 <div class="wrap">33 <header class="entry-header">34 <?php the_title( '<h2 class="entry-title">', '</h2>' ); ?>35 36 <?php twentyseventeen_edit_link( get_the_ID() ); ?>37 38 </header><!-- .entry-header -->39 40 <div class="entry-content">41 <?php42 /* translators: %s: Name of current post */43 the_content( sprintf(44 __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),45 get_the_title()46 ) );47 ?>48 </div><!-- .entry-content -->49 50 </div><!-- .wrap -->51 </div><!-- .panel-content -->52 53 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/page/content-page.php
diff --git a/src/wp-content/themes/twentyseventeen/components/page/content-page.php b/src/wp-content/themes/twentyseventeen/components/page/content-page.php deleted file mode 100644 index 4c470ac..0000000
+ - 1 <?php2 /**3 * Template part for displaying page content in page.php4 *5 * @link https://codex.wordpress.org/Template_Hierarchy6 *7 * @package WordPress8 * @subpackage Twenty_Seventeen9 * @since 1.010 * @version 1.011 */12 13 ?>14 15 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>16 <header class="entry-header">17 <?php the_title( '<h1 class="entry-title">', '</h1>' ); ?>18 <?php twentyseventeen_edit_link( get_the_ID() ); ?>19 </header><!-- .entry-header -->20 <div class="entry-content">21 <?php22 the_content();23 24 wp_link_pages( array(25 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),26 'after' => '</div>',27 ) );28 ?>29 </div><!-- .entry-content -->30 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/post/content-audio.php
diff --git a/src/wp-content/themes/twentyseventeen/components/post/content-audio.php b/src/wp-content/themes/twentyseventeen/components/post/content-audio.php deleted file mode 100644 index b23a919..0000000
+ - 1 <?php2 /**3 * Template part for displaying audio posts4 *5 * @link https://codex.wordpress.org/Template_Hierarchy6 *7 * @package WordPress8 * @subpackage Twenty_Seventeen9 * @since 1.010 * @version 1.011 */12 13 ?>14 15 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>16 <?php17 if ( is_sticky() && is_home() ) :18 echo twentyseventeen_get_svg( array( 'icon' => 'pinned' ) );19 endif;20 ?>21 <header class="entry-header">22 <?php23 if ( 'post' === get_post_type() ) :24 echo '<div class="entry-meta">';25 if ( is_single() ) :26 twentyseventeen_posted_on();27 else :28 echo twentyseventeen_time_link();29 twentyseventeen_edit_link();30 endif;31 echo '</div><!-- .entry-meta -->';32 endif;33 34 if ( is_single() ) {35 the_title( '<h1 class="entry-title">', '</h1>' );36 } else {37 the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' );38 }39 ?>40 </header><!-- .entry-header -->41 42 <?php43 $content = apply_filters( 'the_content', get_the_content() );44 $audio = get_media_embedded_in_content( $content, array( 'audio' ) );45 ?>46 47 <?php if ( '' !== get_the_post_thumbnail() && ! is_single() ) : ?>48 <div class="post-thumbnail">49 <a href="<?php the_permalink(); ?>">50 <?php the_post_thumbnail( 'twentyseventeen-featured-image' ); ?>51 </a>52 </div><!-- .post-thumbnail -->53 <?php endif; ?>54 55 <div class="entry-content">56 57 <?php if ( ! is_single() ) :58 59 // If not a single post, highlight the audio file.60 if ( ! empty( $audio ) ) :61 foreach ( $audio as $audio_html ) {62 echo '<div class="entry-audio">';63 echo $audio_html;64 echo '</div><!-- .entry-audio -->';65 }66 endif;67 68 endif;69 70 if ( is_single() || empty( $audio ) ) :71 72 /* translators: %s: Name of current post */73 the_content( sprintf(74 __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),75 get_the_title()76 ) );77 78 wp_link_pages( array(79 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),80 'after' => '</div>',81 'link_before' => '<span class="page-number">',82 'link_after' => '</span>',83 ) );84 85 endif; ?>86 87 </div><!-- .entry-content -->88 89 <?php if ( is_single() ) : ?>90 <?php twentyseventeen_entry_footer(); ?>91 <?php endif; ?>92 93 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/post/content-excerpt.php
diff --git a/src/wp-content/themes/twentyseventeen/components/post/content-excerpt.php b/src/wp-content/themes/twentyseventeen/components/post/content-excerpt.php deleted file mode 100644 index 0b342d2..0000000
+ - 1 <?php2 /**3 * Template part for displaying posts with excerpts4 *5 * Used in Search Results and for Recent Posts in Front Page panels.6 *7 * @link https://codex.wordpress.org/Template_Hierarchy8 *9 * @package WordPress10 * @subpackage Twenty_Seventeen11 * @since 1.012 * @version 1.013 */14 15 ?>16 17 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>18 19 <header class="entry-header">20 <?php if ( 'post' === get_post_type() ) : ?>21 <div class="entry-meta">22 <?php23 echo twentyseventeen_time_link();24 twentyseventeen_edit_link();25 ?>26 </div><!-- .entry-meta -->27 <?php elseif ( 'page' === get_post_type() && get_edit_post_link() ) : ?>28 <div class="entry-meta">29 <?php twentyseventeen_edit_link(); ?>30 </div><!-- .entry-meta -->31 <?php endif; ?>32 33 <?php the_title( sprintf( '<h2 class="entry-title"><a href="%s" rel="bookmark">', esc_url( get_permalink() ) ), '</a></h2>' ); ?>34 </header><!-- .entry-header -->35 36 <div class="entry-summary">37 <?php the_excerpt(); ?>38 </div><!-- .entry-summary -->39 40 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/post/content-gallery.php
diff --git a/src/wp-content/themes/twentyseventeen/components/post/content-gallery.php b/src/wp-content/themes/twentyseventeen/components/post/content-gallery.php deleted file mode 100644 index 0583fe6..0000000
+ - 1 <?php2 /**3 * Template part for displaying gallery posts4 *5 * @link https://codex.wordpress.org/Template_Hierarchy6 *7 * @package WordPress8 * @subpackage Twenty_Seventeen9 * @since 1.010 * @version 1.011 */12 ?>13 14 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>15 <?php16 if ( is_sticky() && is_home() ) :17 echo twentyseventeen_get_svg( array( 'icon' => 'pinned' ) );18 endif;19 ?>20 <header class="entry-header">21 <?php22 if ( 'post' === get_post_type() ) :23 echo '<div class="entry-meta">';24 if ( is_single() ) :25 twentyseventeen_posted_on();26 else :27 echo twentyseventeen_time_link();28 twentyseventeen_edit_link();29 endif;30 echo '</div><!-- .entry-meta -->';31 endif;32 33 if ( is_single() ) {34 the_title( '<h1 class="entry-title">', '</h1>' );35 } else {36 the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' );37 }38 ?>39 </header><!-- .entry-header -->40 41 <?php if ( '' !== get_the_post_thumbnail() && ! is_single() && ! get_post_gallery() ) : ?>42 <div class="post-thumbnail">43 <a href="<?php the_permalink(); ?>">44 <?php the_post_thumbnail( 'twentyseventeen-featured-image' ); ?>45 </a>46 </div><!-- .post-thumbnail -->47 <?php endif; ?>48 49 <div class="entry-content">50 51 <?php if ( ! is_single() ) :52 53 // If not a single post, highlight the gallery.54 if ( get_post_gallery() ) :55 echo '<div class="entry-gallery">';56 echo get_post_gallery();57 echo '</div>';58 endif;59 60 endif;61 62 if ( is_single() || ! get_post_gallery() ) :63 64 /* translators: %s: Name of current post */65 the_content( sprintf(66 __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),67 get_the_title()68 ) );69 70 wp_link_pages( array(71 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),72 'after' => '</div>',73 'link_before' => '<span class="page-number">',74 'link_after' => '</span>',75 ) );76 77 endif; ?>78 79 </div><!-- .entry-content -->80 81 <?php if ( is_single() ) : ?>82 <?php twentyseventeen_entry_footer(); ?>83 <?php endif; ?>84 85 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/post/content-image.php
diff --git a/src/wp-content/themes/twentyseventeen/components/post/content-image.php b/src/wp-content/themes/twentyseventeen/components/post/content-image.php deleted file mode 100644 index 52bc0a6..0000000
+ - 1 <?php2 /**3 * Template part for displaying image posts4 *5 * @link https://codex.wordpress.org/Template_Hierarchy6 *7 * @package WordPress8 * @subpackage Twenty_Seventeen9 * @since 1.010 * @version 1.011 */12 ?>13 14 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>15 <?php16 if ( is_sticky() && is_home() ) :17 echo twentyseventeen_get_svg( array( 'icon' => 'pinned' ) );18 endif;19 ?>20 <header class="entry-header">21 <?php22 if ( 'post' === get_post_type() ) :23 echo '<div class="entry-meta">';24 if ( is_single() ) :25 twentyseventeen_posted_on();26 else :27 echo twentyseventeen_time_link();28 twentyseventeen_edit_link();29 endif;30 echo '</div><!-- .entry-meta -->';31 endif;32 33 if ( is_single() ) {34 the_title( '<h1 class="entry-title">', '</h1>' );35 } else {36 the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' );37 }38 ?>39 </header><!-- .entry-header -->40 41 <?php if ( '' !== get_the_post_thumbnail() && ! is_single() ) : ?>42 <div class="post-thumbnail">43 <a href="<?php the_permalink(); ?>">44 <?php the_post_thumbnail( 'twentyseventeen-featured-image' ); ?>45 </a>46 </div><!-- .post-thumbnail -->47 <?php endif; ?>48 49 <div class="entry-content">50 51 <?php if ( is_single() || '' === get_the_post_thumbnail() ) :52 53 // Only show content if is a single post, or if there's no featured image.54 /* translators: %s: Name of current post */55 the_content( sprintf(56 __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),57 get_the_title()58 ) );59 60 wp_link_pages( array(61 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),62 'after' => '</div>',63 'link_before' => '<span class="page-number">',64 'link_after' => '</span>',65 ) );66 67 endif; ?>68 69 </div><!-- .entry-content -->70 71 <?php if ( is_single() ) : ?>72 <?php twentyseventeen_entry_footer(); ?>73 <?php endif; ?>74 75 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/post/content-none.php
diff --git a/src/wp-content/themes/twentyseventeen/components/post/content-none.php b/src/wp-content/themes/twentyseventeen/components/post/content-none.php deleted file mode 100644 index c42941b..0000000
+ - 1 <?php2 /**3 * Template part for displaying a message that posts cannot be found4 *5 * @link https://codex.wordpress.org/Template_Hierarchy6 *7 * @package WordPress8 * @subpackage Twenty_Seventeen9 * @since 1.010 * @version 1.011 */12 13 ?>14 15 <section class="no-results not-found">16 <header class="page-header">17 <h1 class="page-title"><?php _e( 'Nothing Found', 'twentyseventeen' ); ?></h1>18 </header>19 <div class="page-content">20 <?php21 if ( is_home() && current_user_can( 'publish_posts' ) ) : ?>22 23 <p><?php printf( __( 'Ready to publish your first post? <a href="%1$s">Get started here</a>.', 'twentyseventeen' ), esc_url( admin_url( 'post-new.php' ) ) ); ?></p>24 25 <?php else : ?>26 27 <p><?php _e( 'It seems we can’t find what you’re looking for. Perhaps searching can help.', 'twentyseventeen' ); ?></p>28 <?php29 get_search_form();30 31 endif; ?>32 </div><!-- .page-content -->33 </section><!-- .no-results --> -
deleted file src/wp-content/themes/twentyseventeen/components/post/content-video.php
diff --git a/src/wp-content/themes/twentyseventeen/components/post/content-video.php b/src/wp-content/themes/twentyseventeen/components/post/content-video.php deleted file mode 100644 index c3e337d..0000000
+ - 1 <?php2 /**3 * Template part for displaying video posts4 *5 * @link https://codex.wordpress.org/Template_Hierarchy6 *7 * @package WordPress8 * @subpackage Twenty_Seventeen9 * @since 1.010 * @version 1.011 */12 ?>13 14 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>15 <?php16 if ( is_sticky() && is_home() ) :17 echo twentyseventeen_get_svg( array( 'icon' => 'pinned' ) );18 endif;19 ?>20 <header class="entry-header">21 <?php22 if ( 'post' === get_post_type() ) :23 echo '<div class="entry-meta">';24 if ( is_single() ) :25 twentyseventeen_posted_on();26 else :27 echo twentyseventeen_time_link();28 twentyseventeen_edit_link();29 endif;30 echo '</div><!-- .entry-meta -->';31 endif;32 33 if ( is_single() ) {34 the_title( '<h1 class="entry-title">', '</h1>' );35 } else {36 the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' );37 }38 ?>39 </header><!-- .entry-header -->40 41 <?php42 $content = apply_filters( 'the_content', get_the_content() );43 $video = get_media_embedded_in_content( $content, array( 'video', 'object', 'embed', 'iframe' ) );44 ?>45 46 <?php if ( '' !== get_the_post_thumbnail() && ! is_single() && empty( $video ) ) : ?>47 <div class="post-thumbnail">48 <a href="<?php the_permalink(); ?>">49 <?php the_post_thumbnail( 'twentyseventeen-featured-image' ); ?>50 </a>51 </div><!-- .post-thumbnail -->52 <?php endif; ?>53 54 <div class="entry-content">55 56 <?php if ( ! is_single() ) :57 58 // If not a single post, highlight the video file.59 if ( ! empty( $video ) ) :60 foreach ( $video as $video_html ) {61 echo '<div class="entry-video">';62 echo $video_html;63 echo '</div>';64 }65 endif;66 67 endif;68 69 if ( is_single() || empty( $video ) ) :70 71 /* translators: %s: Name of current post */72 the_content( sprintf(73 __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),74 get_the_title()75 ) );76 77 wp_link_pages( array(78 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),79 'after' => '</div>',80 'link_before' => '<span class="page-number">',81 'link_after' => '</span>',82 ) );83 84 endif; ?>85 86 </div><!-- .entry-content -->87 88 <?php if ( is_single() ) : ?>89 <?php twentyseventeen_entry_footer(); ?>90 <?php endif; ?>91 92 </article><!-- #post-## --> -
deleted file src/wp-content/themes/twentyseventeen/components/post/content.php
diff --git a/src/wp-content/themes/twentyseventeen/components/post/content.php b/src/wp-content/themes/twentyseventeen/components/post/content.php deleted file mode 100644 index 9b89202..0000000
+ - 1 <?php2 /**3 * Template part for displaying posts4 *5 * @link https://codex.wordpress.org/Template_Hierarchy6 *7 * @package WordPress8 * @subpackage Twenty_Seventeen9 * @since 1.010 * @version 1.011 */12 13 ?>14 15 <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>>16 <?php17 if ( is_sticky() && is_home() ) :18 echo twentyseventeen_get_svg( array( 'icon' => 'pinned' ) );19 endif;20 ?>21 <header class="entry-header">22 <?php23 if ( 'post' === get_post_type() ) :24 echo '<div class="entry-meta">';25 if ( is_single() ) :26 twentyseventeen_posted_on();27 else :28 echo twentyseventeen_time_link();29 twentyseventeen_edit_link();30 endif;31 echo '</div><!-- .entry-meta -->';32 endif;33 34 if ( is_single() ) {35 the_title( '<h1 class="entry-title">', '</h1>' );36 } else {37 the_title( '<h2 class="entry-title"><a href="' . esc_url( get_permalink() ) . '" rel="bookmark">', '</a></h2>' );38 }39 ?>40 </header><!-- .entry-header -->41 42 <?php if ( '' !== get_the_post_thumbnail() && ! is_single() ) : ?>43 <div class="post-thumbnail">44 <a href="<?php the_permalink(); ?>">45 <?php the_post_thumbnail( 'twentyseventeen-featured-image' ); ?>46 </a>47 </div><!-- .post-thumbnail -->48 <?php endif; ?>49 50 <div class="entry-content">51 <?php52 /* translators: %s: Name of current post */53 the_content( sprintf(54 __( 'Continue reading<span class="screen-reader-text"> "%s"</span>', 'twentyseventeen' ),55 get_the_title()56 ) );57 58 wp_link_pages( array(59 'before' => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),60 'after' => '</div>',61 'link_before' => '<span class="page-number">',62 'link_after' => '</span>',63 ) );64 ?>65 </div><!-- .entry-content -->66 67 <?php if ( is_single() ) : ?>68 <?php twentyseventeen_entry_footer(); ?>69 <?php endif; ?>70 71 </article><!-- #post-## --> -
src/wp-content/themes/twentyseventeen/footer.php
diff --git a/src/wp-content/themes/twentyseventeen/footer.php b/src/wp-content/themes/twentyseventeen/footer.php index e911c1a..2d72029 100644
a b 19 19 <footer id="colophon" class="site-footer" role="contentinfo"> 20 20 <div class="wrap"> 21 21 <?php 22 get_template_part( ' components/footer/footer', 'widgets' );22 get_template_part( 'template-parts/footer/footer', 'widgets' ); 23 23 24 24 if ( has_nav_menu( 'social' ) ) : ?> 25 25 <nav class="social-navigation" role="navigation" aria-label="<?php _e( 'Footer Social Links Menu', 'twentyseventeen' ); ?>"> … … 35 35 </nav><!-- .social-navigation --> 36 36 <?php endif; 37 37 38 get_template_part( ' components/footer/site', 'info' );38 get_template_part( 'template-parts/footer/site', 'info' ); 39 39 ?> 40 40 </div><!-- .wrap --> 41 41 </footer><!-- #colophon --> -
src/wp-content/themes/twentyseventeen/front-page.php
diff --git a/src/wp-content/themes/twentyseventeen/front-page.php b/src/wp-content/themes/twentyseventeen/front-page.php index ea4ddc9..5556888 100644
a b get_header(); ?> 20 20 <?php // Show the selected frontpage content. 21 21 if ( have_posts() ) : 22 22 while ( have_posts() ) : the_post(); 23 get_template_part( ' components/page/content', 'front-page' );23 get_template_part( 'template-parts/page/content', 'front-page' ); 24 24 endwhile; 25 25 else : // I'm not sure it's possible to have no posts when this page is shown, but WTH. 26 get_template_part( ' components/post/content', 'none' );26 get_template_part( 'template-parts/post/content', 'none' ); 27 27 endif; ?> 28 28 29 29 <?php … … get_header(); ?> 31 31 $panels = array( '1', '2', '3', '4' ); 32 32 $titles = array(); 33 33 34 global $twentyseventeencounter; // Used in components/page/content-front-page-panels.php file.34 global $twentyseventeencounter; // Used in template-parts/page/content-front-page-panels.php file. 35 35 36 36 if ( 0 !== twentyseventeen_panel_count() || is_customize_preview() ) : // If we have pages to show. 37 37 … … get_header(); ?> 44 44 set_query_var( 'panel', $panel ); 45 45 46 46 $titles[] = get_the_title(); // Put page titles in an array for use in navigation. 47 get_template_part( ' components/page/content', 'front-page-panels' );47 get_template_part( 'template-parts/page/content', 'front-page-panels' ); 48 48 49 49 wp_reset_postdata(); 50 50 else : -
src/wp-content/themes/twentyseventeen/header.php
diff --git a/src/wp-content/themes/twentyseventeen/header.php b/src/wp-content/themes/twentyseventeen/header.php index f76bbf3..dc173d6 100644
a b 28 28 29 29 <header id="masthead" class="site-header" role="banner"> 30 30 31 <?php get_template_part( ' components/header/header', 'image' ); ?>31 <?php get_template_part( 'template-parts/header/header', 'image' ); ?> 32 32 33 33 <?php if ( has_nav_menu( 'top' ) ) : ?> 34 34 <div class="navigation-top"> 35 35 <div class="wrap"> 36 <?php get_template_part( ' components/navigation/navigation', 'top' ); ?>36 <?php get_template_part( 'template-parts/navigation/navigation', 'top' ); ?> 37 37 </div><!-- .wrap --> 38 38 </div><!-- .navigation-top --> 39 39 <?php endif; ?> -
src/wp-content/themes/twentyseventeen/index.php
diff --git a/src/wp-content/themes/twentyseventeen/index.php b/src/wp-content/themes/twentyseventeen/index.php index 144ef9a..4e1186b 100644
a b get_header(); ?> 42 42 * If you want to override this in a child theme, then include a file 43 43 * called content-___.php (where ___ is the Post Format name) and that will be used instead. 44 44 */ 45 get_template_part( ' components/post/content', get_post_format() );45 get_template_part( 'template-parts/post/content', get_post_format() ); 46 46 47 47 endwhile; 48 48 … … get_header(); ?> 54 54 55 55 else : 56 56 57 get_template_part( ' components/post/content', 'none' );57 get_template_part( 'template-parts/post/content', 'none' ); 58 58 59 59 endif; 60 60 ?> -
src/wp-content/themes/twentyseventeen/page.php
diff --git a/src/wp-content/themes/twentyseventeen/page.php b/src/wp-content/themes/twentyseventeen/page.php index 850b2ba..96211f4 100644
a b get_header(); ?> 24 24 <?php 25 25 while ( have_posts() ) : the_post(); 26 26 27 get_template_part( ' components/page/content', 'page' );27 get_template_part( 'template-parts/page/content', 'page' ); 28 28 29 29 // If comments are open or we have at least one comment, load up the comment template. 30 30 if ( comments_open() || get_comments_number() ) : -
src/wp-content/themes/twentyseventeen/search.php
diff --git a/src/wp-content/themes/twentyseventeen/search.php b/src/wp-content/themes/twentyseventeen/search.php index 6a22181..a521e4b 100644
a b get_header(); ?> 35 35 * If you want to overload this in a child theme then include a file 36 36 * called content-search.php and that will be used instead. 37 37 */ 38 get_template_part( ' components/post/content', 'excerpt' );38 get_template_part( 'template-parts/post/content', 'excerpt' ); 39 39 40 40 endwhile; // End of the loop. 41 41 -
src/wp-content/themes/twentyseventeen/single.php
diff --git a/src/wp-content/themes/twentyseventeen/single.php b/src/wp-content/themes/twentyseventeen/single.php index f1b3721..704560b 100644
a b get_header(); ?> 20 20 /* Start the Loop */ 21 21 while ( have_posts() ) : the_post(); 22 22 23 get_template_part( ' components/post/content', get_post_format() );23 get_template_part( 'template-parts/post/content', get_post_format() ); 24 24 25 25 // If comments are open or we have at least one comment, load up the comment template. 26 26 if ( comments_open() || get_comments_number() ) :