[wp-trac] [WordPress Trac] #17552: Plugin editor incorrectly calls some inactive.

WordPress Trac wp-trac at lists.automattic.com
Tue May 24 23:26:48 UTC 2011


#17552: Plugin editor incorrectly calls some inactive.
--------------------------+----------------------------
 Reporter:  dd32          |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Future Release
Component:  Plugins       |    Version:  3.1
 Severity:  normal        |   Keywords:  needs-patch
--------------------------+----------------------------
 The plugin editor has a helpful bit of text at the top to specify if the
 current file is active on the site or not; This works fine in most cases,
 however, I've noticed that it only works for the ''plugin file itself''.

 Ie. Editing akismet/akismet.php will specify it's active, Editing
 akismet/admin.php will show as inactive.

 This is due to the use of is_plugin_active() from memory. The solution to
 this would be to run is_plugin_active() on {{{$_GET['plugin']}}} instead
 of the file being edited.

 {{{$_GET['plugin']}}} has it's own bug however, It's set to whichever file
 was edited before you loaded the current file (when you switch between
 files in a plugin that is), which in some cases will be correct, in many
 others when you're editing multiple files, It'll be incorrect.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/17552>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list