I agree that all those things are good practise, but I feel there is more to it. A code map along the lines of "Well, we're going to have a main routine which fires up different function libraries depending on the cgi params, each case will be handled like this:....". You know, a general layout including future directions for the coders to go in. You need
something like that when you have three people working on the same code.
And yes, their main problem was that they didn't understand OO in the slightest, and were using global variables rather than presenting methods/data in a useful, consistant way. I suspect if they had sat down and written out what they were trying to do, they would have started to spot ways to improve their code. Perhaps that's program design versus programming. The code had apparently grown out of a 'quick hack' that someone put together one day, so it was kinda lumpy and directionless.
In my mind good documentation is an art as much as coding or writing is. It isn't necessarily explaining what every line does. Having said that I'm off to edit my code snippit before somebody reads all my posts and plays spot the hippocritic bastard :)
____________________
Jeremy
I didn't believe in evil until I dated it.