About Page: Add Cloudup embed and cache the embeds as site transients.

Merge of [35823] to the 4.4 branch.

Props wonderboymusic.
See #34663.
Built from https://develop.svn.wordpress.org/branches/4.4@35824


git-svn-id: http://core.svn.wordpress.org/branches/4.4@35788 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Dominik Schilling 2015-12-07 23:32:27 +00:00
parent 8529c19a8d
commit 264b0beca2
2 changed files with 23 additions and 3 deletions

View File

@ -83,14 +83,34 @@ include( ABSPATH . 'wp-admin/admin-header.php' );
<div class="feature-section two-col">
<div class="col">
<div class="embed-container">
<?php echo wp_oembed_get( 'https://make.wordpress.org/core/2015/10/28/new-embeds-feature-in-wordpress-4-4/' ); ?>
<?php
$embed1 = get_site_transient( 'about-page-embed-1' );
if ( false === $embed1 ) {
$embed1 = wp_oembed_get( 'https://make.wordpress.org/core/2015/10/28/new-embeds-feature-in-wordpress-4-4/' );
if ( ! $embed1 ) {
$embed1 = '{{unknown}}';
}
set_site_transient( 'about-page-embed-1', $embed1 );
}
echo '{{unknown}}' !== $embed1 ? $embed1 : '';
?>
</div>
<h3><?php _e( 'Embed your WordPress content' ); ?></h3>
<p><?php _e( 'Now you can embed your posts on other sites, even other WordPress sites. Simply drop a post URL into the editor and see an instant embed preview, complete with the title, excerpt, and featured image if you&#8217;ve set one. We&#8217;ll even include your site icon and links for comments and sharing.' ); ?></p>
</div>
<div class="col">
<div class="embed-container">
<?php echo wp_oembed_get( '' ); ?>
<?php
$embed2 = get_site_transient( 'about-page-embed-2' );
if ( false === $embed2 ) {
$embed2 = wp_oembed_get( 'https://cloudup.com/cD3duXiAI5k' );
if ( ! $embed2 ) {
$embed2 = '{{unknown}}';
}
set_site_transient( 'about-page-embed-2', $embed2 );
}
echo '{{unknown}}' !== $embed2 ? $embed2 : '';
?>
</div>
<h3><?php _e( 'Even more embed providers' ); ?></h3>
<p><?php _e( 'In addition to post embeds, WordPress 4.4 also adds support for five new oEmbed providers: Cloudup, Reddit&nbsp;Comments, ReverbNation, Speaker&nbsp;Deck, and VideoPress.' ); ?></p>

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.4-RC1-35821';
$wp_version = '4.4-RC1-35824';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.