IWETHEY v. 0.3.0 | TODO
1,095 registered users | 0 active users | 0 LpH | Statistics
Login | Create New User
IWETHEY Banner

Welcome to IWETHEY!

New I'd suspect reuse of another routine.
I didn't take much in the way of CS classes, either, so have your salt-shaker handy.

Presumably the code was written over time, perhaps by several people, and they got sloppy about the naming. Or they cut-and-pasted code from other programs that had the needed functionality, and didn't refactor it.

My understanding is that Best Practices generally say that you should have private routines that pass pointers or values back and forth, and not depend on magic names to move data around through the code. Most of the guts of the work should be done with private variables. (IOW, Globals Variables are Bad - http://c2.com/cgi/wi...alVariablesAreBad )

I can't see any benefit of taking a variable that holds user-entered data and renaming it to use elsewhere (unless it's an attempt to minimize Globals). Ultimately, the information gets pushed onto a CPU register - the transistors don't care what you call a variable.

HTH a little. Corrections welcome.

Cheers,
Scott.
New Oh, it's definitely *not* to avoid globals
I've got one function that passes 35 globals. The "design" -- such as it is -- seems to be: "Pass everything everywhere, because you never know what you might need."
--

Drew
New Sounds like one of my old QuickBasic programs. =(
     Why would you rename variables? - (drook) - (13)
         I'd suspect reuse of another routine. - (Another Scott) - (2)
             Oh, it's definitely *not* to avoid globals - (drook) - (1)
                 Sounds like one of my old QuickBasic programs. =( -NT - (Another Scott)
         Re: Why would you rename variables? - (boxley) - (7)
             Not quite - (drook) - (6)
                 anything special about $_request? - (boxley) - (5)
                     Special variable in PHP - (drook) - (4)
                         Actually, they can be modified. - (static) - (2)
                             Did not know that - (drook) - (1)
                                 I was rather glad it was possible. - (static)
                         If speed counts ... - (crazy)
         There is, but it doesn't look like that's what is being done - (malraux) - (1)
             Like I told Wade, I didn't think that was an issue here - (drook)

If I'm going to visit an exotic foreign land with L. Ron Hubbard or Jim Jones, I'll opt for the Scientology tour.
46 ms