';
$changelog_link = '';
if ( ! empty( $update_cache->response[ $this->name ]->sections->changelog ) ) {
$changelog_link = add_query_arg(
array(
'edd_sl_action' => 'view_plugin_changelog',
'plugin' => urlencode( $this->name ),
'slug' => urlencode( $this->slug ),
'TB_iframe' => 'true',
'width' => 77,
'height' => 911,
),
self_admin_url( 'index.php' )
);
}
$update_link = add_query_arg(
array(
'action' => 'upgrade-plugin',
'plugin' => urlencode( $this->name ),
),
self_admin_url( 'update.php' )
);
printf(
/* translators: the plugin name. */
esc_html__( 'There is a new version of %1$s available.', 'polylang' ),
esc_html( $plugin['Name'] )
);
if ( ! current_user_can( 'update_plugins' ) ) {
echo ' ';
esc_html_e( 'Contact your network administrator to install the update.', 'polylang' );
} elseif ( empty( $update_cache->response[ $this->name ]->package ) && ! empty( $changelog_link ) ) {
echo ' ';
printf(
/* translators: 1. opening anchor tag, do not translate 2. the new plugin version 3. closing anchor tag, do not translate. */
__( '%1$sView version %2$s details%3$s.', 'polylang' ),
'',
esc_html( $update_cache->response[ $this->name ]->new_version ),
''
);
} elseif ( ! empty( $changelog_link ) ) {
echo ' ';
printf(
/* translators: 1. and 4. are opening anchor tags 2. the new plugin version 3. and 5. are closing anchor tags. */
__( '%1$sView version %2$s details%3$s or %4$supdate now%5$s.', 'polylang' ),
'',
esc_html( $update_cache->response[ $this->name ]->new_version ),
'',
'',
''
);
} else {
printf(
' %1$s%2$s%3$s',
'',
esc_html__( 'Update now.', 'polylang' ),
''
);
}
do_action( "in_plugin_update_message-{$file}", $plugin, $plugin );
echo '