PluginProbe
Phone Button / trunk
Phone Button vtrunk
trunk 1.0.0 1.0.1 1.0.3 1.1.0 1.1.1 2.0.0 2.1.0 2.1.1 2.1.2
← All changes | index.php +24 -1 2.1.0trunk View file →
@@ -3,9 +3,9 @@
3 3 /*
4 4 Plugin Name: YYDevelopment - Phone Button
5 5 Plugin URI: https://www.yydevelopment.com/yydevelopment-wordpress-plugins/
6 6 Description: Simple plugin that allow you add phone button to your site
7 -Version: 2.0.0
7 +Version: 2.1.2
8 8 Author: YYDevelopment
9 9 Author URI: https://www.yydevelopment.com/
10 10 */
11 11
@@ -66,8 +66,31 @@
66 66 return $actions;
67 67 } //function yydev_phone_btn_add_settings_link( $actions, $plugin_file ) {
68 68
69 69 add_filter( 'plugin_action_links', 'yydev_phone_btn_add_settings_link', 10, 5 );
70 +
71 +// ================================================
72 +// Add donate page to the plugin menu info
73 +// ================================================
74 +
75 +add_filter( 'plugin_action_links', function($actions, $plugin_file) {
76 +
77 + static $plugin;
78 +
79 + if (!isset($plugin)) { $plugin = plugin_basename(__FILE__); }
80 +
81 + if ($plugin == $plugin_file) {
82 +
83 + $admin_page_url = esc_url( menu_page_url( 'phone-button', false ) );
84 + $donate = array('donate' => '<a target="_blank" href="https://www.yydevelopment.com/coffee-break/?plugin=phone-button">Donate</a>');
85 +
86 + $actions = array_merge($donate, $actions);
87 +
88 + } // if ($plugin == $plugin_file) {
89 +
90 + return $actions;
91 +
92 +}, 10, 5 );
70 93
71 94 // ================================================
72 95 // output the data into the page front end
73 96 // ================================================