March 2011
Beginner to intermediate
300 pages
7h 23m
English
PHP as a language is particularly vulnerable to naming collisions, and this is especially prevalent in WordPress plugins where many authors are not particularly aware or sensitive about this problem. If your site is running a lot of plugins, you are increasing the odds that a naming conflict might occur. While debugging a plugin, one of the first things that you should do is disable all of your other plugins so you can isolate problems.
We have seen a lot of useless attempts to prevent naming collisions when plugin authors wrap their function definitions in a big if-block:
if ( !function_exists('myfunction') )
{
function myfunction()
{
// Do stuff
}
}Do not think that your plugin is safe if you use if-blocks like this! This is ...
Read now
Unlock full access