html-notice-simplify-commerce.php 1.1 KB

123456789101112131415161718192021222324
  1. <?php
  2. /**
  3. * Admin View: Notice - Simplify Commerce.
  4. */
  5. if ( ! defined( 'ABSPATH' ) ) {
  6. exit;
  7. }
  8. $plugin_slug = 'woocommerce-gateway-simplify-commerce';
  9. if ( current_user_can( 'install_plugins' ) ) {
  10. $url = wp_nonce_url( self_admin_url( 'update.php?action=install-plugin&plugin=' . $plugin_slug ), 'install-plugin_' . $plugin_slug );
  11. } else {
  12. $url = 'https://wordpress.org/plugins/' . $plugin_slug;
  13. }
  14. ?>
  15. <div id="message" class="updated woocommerce-message">
  16. <a class="woocommerce-message-close notice-dismiss" href="<?php echo esc_url( wp_nonce_url( add_query_arg( 'wc-hide-notice', 'simplify_commerce' ), 'woocommerce_hide_notices_nonce', '_wc_notice_nonce' ) ); ?>"><?php _e( 'Dismiss', 'woocommerce' ); ?></a>
  17. <p><?php _e( '<strong>The Simplify Commerce payment gateway is deprecated</strong> &#8211; Please install our new free Simplify Commerce plugin from WordPress.org. Simplify Commerce will be removed from WooCommerce core in a future update.', 'woocommerce' ); ?></p>
  18. <p class="submit"><a href="<?php echo esc_url( $url ); ?>" class="wc-update-now button-primary"><?php _e( 'Install our new Simplify Commerce plugin', 'woocommerce' ); ?></a></p>
  19. </div>