Changeset 2983 for sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/admin/metabox/class-custom-fields.php
- Timestamp:
- 04/19/2016 08:09:35 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/admin/metabox/class-custom-fields.php
r2655 r2983 9 9 class Custom_Fields { 10 10 static function display() { 11 $post = get_post();11 $post = get_post(); 12 12 $fields = array( 13 13 'version' => 'Latest Plugin Version', … … 22 22 'header_description' => 'Plugin Description', 23 23 ); 24 24 25 echo '<dl>'; 25 26 foreach ( $fields as $field => $text ) { 26 if ( ! ($value = get_post_meta( $post->ID, $field, true )) ) {27 if ( ! $value = get_post_meta( $post->ID, $field, true ) ) { 27 28 continue; 28 29 } 29 30 printf( '<dt>%s</dt><dd>%s</dd>', esc_html( $text ), make_clickable( esc_html( $value ) ) ); 30 31 } 31 // Description is stored in the post_excerpt rather than meta32 printf( '<dt>%s</dt><dd>%s</dd>', esc_html( $fields['header_description'] ), get_the_excerpt() );33 32 echo '</dl>'; 34 33 }
Note: See TracChangeset
for help on using the changeset viewer.