Name Collisions in PHP

I came across this passage in Professional WordPress Plugin Development:

[…] it’s essential that you prefix everything with a unique prefix. […] one of the most common errors in plugins is using all too common names for function and variables. […] the website will break because you can’t have two functions with the same name in PHP.

So, if I install two plugins from different developers, I cross my fingers and hope that they haven’t used any of the same variable or function names, else my site will suffer the consequences. Plugins are compatible by chance.

Leave a Reply

Your email address will not be published. Required fields are marked *