I was experimenting around with adding administration menus via plugins and found this strange error. I took the sample 'Menu Test' plugin on this page:
and placed it in two locations:
1. in wp-content/plugins/
2. in wp-content/plugins/menutest/
In #1, clicking 'Test Toplevel' works perfectly.
In #2, clicking 'Test Toplevel' gives the following error:
Fatal error: Cannot redeclare mt_add_pages() (previously declared in C:\Development\wordpress\wp-content\plugins\menutest\menutest.php:13) in C:\Development\wordpress\wp-content\plugins\menutest\menutest.php on line 11
Somehow a function redeclaration check isn't being applied when the base plugin file is placed in a subdirectory of plugins/. This seems to only be a problem when the plugin uses add_menu_page (since Spam Karma 2 is housed in a subdirectory and has no problems with the menus).
Anyone have any ideas?
I'm using version 1.5.2[/edit]