Changeset 27623
- Timestamp:
- 03/19/2014 07:12:32 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-content/themes/twentyfourteen/functions.php
r27595 r27623 439 439 440 440 /** 441 * Extend the default WordPress post classes.442 *443 * Adds a post class to denote:444 * Non-password protected page with a post thumbnail.445 *446 * @since Twenty Fourteen 1.0447 *448 * @param array $classes A list of existing post class values.449 * @return array The filtered post class list.450 */451 function twentyfourteen_post_classes( $classes ) {452 if ( ! post_password_required() && ! is_attachment() && has_post_thumbnail() ) {453 $classes[] = 'has-post-thumbnail';454 }455 456 return $classes;457 }458 add_filter( 'post_class', 'twentyfourteen_post_classes' );459 460 /**461 441 * Create a nicely formatted and more specific title element text for output 462 442 * in head of document, based on current view.
Note: See TracChangeset
for help on using the changeset viewer.