PluginProbe
GiveWP – Donation Plugin and Fundraising Platform / 2.3.0
GiveWP – Donation Plugin and Fundraising Platform v2.3.0
4.17.0 4.16.9 4.16.8.1 4.16.8 4.16.7.2 4.16.7.1 4.16.7 4.16.6.1 4.16.6 4.16.5.1 4.16.5 4.16.4 4.16.3 4.16.2 4.16.1 4.16.0 4.15.5 4.15.4 4.15.3 4.15.2 4.15.1 4.15.0 2.3.0 2.3.1 2.3.2 All 256 releases
give / includes / admin / upgrades / views / plugins-update-section.php

plugins-update-section.php in GiveWP – Donation Plugin and Fundraising Platform 2.3.0, at includes/admin/upgrades/views/plugins-update-section.php

67 lines 1.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /* @var Give_Updates $give_updates */
3 $plugins = $give_updates->get_updates( 'plugin' );
4 if ( empty( $plugins ) ) {
5 return;
6 }
7
8 ob_start();
9 foreach ( $plugins as $plugin_data ) {
10 if ( 'active' != $plugin_data['Status'] || 'add-on' != $plugin_data['Type'] ) {
11 continue;
12 }
13
14 $plugin_name = $plugin_data['Name'];
15 $author_name = $plugin_data['Author'];
16
17 // Link the plugin name to the plugin URL if available.
18 if ( ! empty( $plugin_data['PluginURI'] ) ) {
19 $plugin_name = sprintf(
20 '<a href="%s" title="%s">%s</a> (%s)',
21 esc_url( $plugin_data['PluginURI'] ),
22 esc_attr__( 'Visit plugin homepage', 'give' ),
23 $plugin_name,
24 esc_html( $plugin_data['Version'] )
25 );
26 }
27
28 // Link the author name to the author URL if available.
29 if ( ! empty( $plugin_data['AuthorURI'] ) ) {
30 $author_name = sprintf(
31 '<a href="%s" title="%s">%s</a>',
32 esc_url( $plugin_data['AuthorURI'] ),
33 esc_attr__( 'Visit author homepage', 'give' ),
34 $author_name
35 );
36 }
37 ?>
38 <tr>
39 <td><?php echo wp_kses( $plugin_name, wp_kses_allowed_html( 'post' ) ); ?></td>
40 <td>
41 <?php
42 echo true === $plugin_data['License']
43 ? sprintf(
44 '<span class="dashicons dashicons-yes"></span>%s',
45 __( 'Licensed', 'give' )
46 )
47 : sprintf(
48 '<span data-tooltip="%s"><span class="dashicons dashicons-no-alt"></span>%s</span>',
49 __( 'Unlicensed add-ons cannot be updated. Please purchase or renew a valid license.', 'give' ),
50 __( 'Unlicensed', 'give' )
51 );
52
53 echo sprintf(
54 ' &ndash; %s &ndash; %s',
55 sprintf( _x( 'by %s', 'by author', 'give' ), wp_kses( $author_name, wp_kses_allowed_html( 'post' ) ) ),
56 sprintf( __( '(Latest Version: %s)' ), $plugin_data['update']->new_version )
57 );
58 ?>
59 </td>
60 </tr>
61 <?php
62 }
63 echo sprintf(
64 '<table><tbody>%s</tbody></table>',
65 ob_get_clean()
66 );
67 ?>