| 1 |
<?php declare(strict_types=1); |
| 2 |
|
| 3 |
namespace MultiSafepay\WooCommerce\Utils; |
| 4 |
|
| 5 |
/** |
| 6 |
* This class defines the custom links added to the WordPress plugin list for this plugin |
| 7 |
*/ |
| 8 |
class CustomLinks { |
| 9 |
|
| 10 |
/** |
| 11 |
* Filter and add links to the WordPress plugin list |
| 12 |
* |
| 13 |
* @see https://developer.wordpress.org/reference/hooks/plugin_action_links_plugin_file/ |
| 14 |
* |
| 15 |
* @param array $links |
| 16 |
* @return array |
| 17 |
*/ |
| 18 |
public function get_links( array $links ): array { |
| 19 |
$custom_links = array( |
| 20 |
'<a href="' . admin_url( 'admin.php?page=multisafepay-settings' ) . '">' . __( 'Settings', 'multisafepay' ) . '</a>', |
| 21 |
'<a target="_blank" href="https://docs.multisafepay.com/docs/woocommerce">' . __( 'Docs & Support', 'multisafepay' ) . '</a>', |
| 22 |
); |
| 23 |
return array_merge( $custom_links, $links ); |
| 24 |
} |
| 25 |
} |
| 26 |
|