PDA

View Full Version : Tabs or spaces?


eva2000
Sun 26th Aug '01, 1:01am
Which do you use and why?

http://phpbuilder.com/columns/tim20010101.php3

reveltaion456
Sun 26th Aug '01, 1:27am
I really have no idea if I am thinking about the right thing here but here goes.

When I modify vBulletin templates, I use spaces because whenever I press tab, it moves over to the next forum (or submit button) and I am too lazy to go through the process of converting to an editable file, etc.

Mark Hensler
Sun 26th Aug '01, 3:01am
I agree with the author on the tab thing. I have forever used tabs, and plan to forever more use tabs.
I document all functions I make in this fashion:
function Subtraction($arg1, $arg2) {
/**
* Function takes two integers ($arg1, $arg2) and subtracts the first from the second.
*
* Function does no error trapping.
*
* Function return integer
*/
return ($arg2 - $arg1);
}

I recommend to anyone who calls themself a PHP programmer to read the PEAR documentation. And most importantly, document your code!

eva2000
Sun 26th Aug '01, 3:09am
i think that would be my major problem.. documenting my code.. i'm pretty lazy with this kind of stuff :o