Functions are amazing. Working with huge function files is not.
I like to group all my functions into different “function files” to keep everything nice and clean. For example, I’ll keep all my functions that clean up various strings or elements in a clean.php file.
This is great because I don’t have to scan a 50000 line PHP file to find the function that I’m looking for.
As your application grows, the number of function files may grow with it. This can pose a problem. Did you remember to include the new function file in all necessary scripts?
