">


response[$plugin_file] ) ) { $addon['needs_update'] = true; } else { $addon['needs_update'] = false; } // Set plugin data for 'status' from active, inactive, and uninstalled. if ( is_plugin_active( $plugin_file ) ) { $addon['status'] = 'active'; } elseif ( file_exists( $plugin_file_abs ) ) { $addon['status'] = 'inactive'; } else { $addon['status'] = 'uninstalled'; } // Set plugin data for whether this user can access this Add On. if ( pmpro_can_download_addon_with_license( $addon['License'] ) ) { $addon['access'] = true; } else { $addon['access'] = false; } // Build the selectors for the Add On in the list. $classes = array(); $classes[] = 'add-on-container'; $classes[] = 'add-on-' . $addon['status']; if ( ! empty( $addon['needs_update'] ) ) { $classes[] = 'add-on-needs-update'; } $class = implode( ' ', array_unique( $classes ) ); // Build the data-view for the Add On in the list. $views = array(); $views[] = 'all'; foreach ( $addon_cats as $cat => $slugs ) { if ( in_array( $addon['Slug'], $slugs ) ) { $views[] = $cat; } } if ( in_array( $addon['License'], array( 'free', 'wordpress.org' ) ) ) { $views[] = 'free'; } if ( pmpro_license_type_is_premium( $addon['License'] ) ) { $views[] = 'premium'; } $view = implode( ' ', array_unique( $views ) ); ?>
<?php echo esc_attr( $addon['Name'] ); ?>

' . esc_html( $addon['Author'] ) . ''; $plugin_meta[] = sprintf( __( 'By %s' ), $author ); } //$plugin_meta = apply_filters( 'plugin_row_meta', $plugin_meta, $plugin_file, $addon, $addon['status']); echo implode( ' | ', $plugin_meta ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>

' . wp_kses_post( $license_label ) . ''; } else { printf( /* translators: %s - Add On license label. */ esc_html__( 'License: %s', 'paid-memberships-pro' ), '' . wp_kses_post( $license_label ) . '' ); } ?>

' . wp_kses_post( $status_label ) . '' ); ?>

'', 'style' => 'button pmproAddOnActionButton', 'hidden_fields' => array() ); if ( ! empty( $addon['needs_update'] ) ) { $action_button['label'] = __( 'Update Now', 'paid-memberships-pro' ); if ( empty( $addon['access'] ) ) { // Can't update it. Popup. $action_button['hidden_fields']['pmproAddOnAdminAction'] = 'license'; $action_button['hidden_fields']['pmproAddOnAdminName'] = $addon['ShortName']; $action_button['hidden_fields']['pmproAddOnAdminLicense'] = ucwords( $addon['License' ] ); } else { $action_button['hidden_fields']['pmproAddOnAdminAction'] = 'update'; $action_button['hidden_fields']['pmproAddOnAdminActionUrl'] = wp_nonce_url( self_admin_url( add_query_arg( array( 'action' => 'upgrade-plugin', 'plugin' => $plugin_file ), 'update.php' ) ), 'upgrade-plugin_' . $plugin_file ); } } elseif ( $addon['status'] === 'uninstalled' ) { $action_button['label'] = __( 'Install', 'paid-memberships-pro' ); if ( empty( $addon['access'] ) ) { // Can't update it. Popup. $action_button['hidden_fields']['pmproAddOnAdminAction'] = 'license'; $action_button['hidden_fields']['pmproAddOnAdminName'] = $addon['ShortName']; $action_button['hidden_fields']['pmproAddOnAdminLicense'] = ucwords( $addon['License' ] ); } else { $action_button['hidden_fields']['pmproAddOnAdminAction'] = 'install'; $action_button['hidden_fields']['pmproAddOnAdminActionUrl'] = wp_nonce_url( self_admin_url( add_query_arg( array( 'action' => 'install-plugin', 'plugin' => $addon['Slug'] ), 'update.php' ) ), 'install-plugin_' . $addon['Slug'] ); } } elseif ( $addon['status'] === 'inactive' ) { $action_button['label'] = __( 'Activate', 'paid-memberships-pro' ); $action_button['hidden_fields']['pmproAddOnAdminAction'] = 'activate'; $action_button['hidden_fields']['pmproAddOnAdminActionUrl'] = wp_nonce_url( self_admin_url( add_query_arg( array( 'action' => 'activate', 'plugin' => $plugin_file ), 'plugins.php' ) ), 'activate-plugin_' . $plugin_file ); } elseif ( $addon['status'] === 'active' ) { $actions = apply_filters( 'plugin_action_links_' . $plugin_file, array(), $plugin_file, $addon, $addon['status'] ); if ( ! empty( $actions ) ) { $action_button = str_replace( ' $value ) { ?>
Paid Memberships Pro(c) - All Rights Reserved

', '' ); ?>

Enter your license key here', 'paid-memberships-pro' ) ), esc_url( admin_url( 'admin.php?page=pmpro-license' ) ) ); ?>