I have made a plugin that changes the previous plugin that I wrote and adds some extra stuff. I want to make a conscious in the settings page of my old plugin, with a link to download and install my new plugin and informs that the old plugins are no longer supported by its developers. Currently, from the plugin page of my admin panel, look like this link:
http://www.example.com/wp-admin/network/update.php?action=install URI While creating, I feel that at least two things are to be kept in mind:
/ P>
Check if this is a multi-site setup
Make sure I generate the correct non. Do anyone know how to do it properly? Thanks in advance for your help?
I have received an answer. In wp-admin / import.php , this is a great example of how it works. Here's my implementation:
$ plugin_name = 'my_plugin_name'; $ Install_link = '& lt; A href = "'. Esc_url (' plugin-install.php? Tab = plugin-notification & plugin = '. $ Plugin_name.' & Amp;; TB_iframe = true & width = 600 & height = 550 ' )). ' More information about 'Class = "thickbox" title = ". $ Plugin_name. "" & Gt; Install '$ Plugin_name' & lt; / A & gt; '; Then output the link tag anywhere in your admin pages.
If you want to get fancy and add thicker box mode window effect, then use the function ad_thickbox () and attach that action which the general administrator asked in the request Such as: add_action ('admin_menu', 'my_plugin_add_thickbox'); Function my_plugin_add_thickbox () {add_thickbox (); } Should do this!
Comments
Post a Comment