From 412161de03c677829a9ebe6f28df3b69fec8aa07 Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Wed, 17 Apr 2013 20:57:44 +0000 Subject: [PATCH] Standardize post format postmeta keys around the ones already used by the Crowd Favorite plugin. props wonderboymusic. fixes #24010. git-svn-id: http://core.svn.wordpress.org/trunk@24021 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/includes/post-formats.php | 88 ++++++++++++++++----------- wp-admin/includes/post.php | 21 ++++--- wp-admin/js/post-formats.js | 12 ++-- wp-includes/js/autosave.js | 2 +- wp-includes/media.php | 25 ++++---- wp-includes/post-formats.php | 97 ++++++++++++++++++++++-------- wp-includes/revision.php | 16 ++--- 7 files changed, 164 insertions(+), 97 deletions(-) diff --git a/wp-admin/includes/post-formats.php b/wp-admin/includes/post-formats.php index 1ea5b34775..2db8b18699 100644 --- a/wp-admin/includes/post-formats.php +++ b/wp-admin/includes/post-formats.php @@ -11,28 +11,30 @@ $format_meta = get_post_format_meta( $post_ID );
- +
- +
- +
', esc_url( $image ), get_the_title( $format_meta['image'] ) ); - } elseif ( preg_match( '/' . get_shortcode_regex() . '/s', $format_meta['image'] ) ) { - echo do_shortcode( $format_meta['image'] ); - } elseif ( ! preg_match( '#<[^>]+>#', $format_meta['image'] ) ) { - printf( '', esc_url( $format_meta['image'] ) ); + } elseif ( preg_match( '/' . get_shortcode_regex() . '/s', $value ) ) { + echo do_shortcode( $value ); + } elseif ( ! preg_match( '#<[^>]+>#', $value ) ) { + printf( '', esc_url( $value ) ); } else { - echo $format_meta['image']; + echo $value; } ?>
@@ -43,7 +45,7 @@ $format_meta = get_post_format_meta( $post_ID ); else _e( 'Image URL' ); ?> - + -