06-10-2009, 09:46 PM
|
#6 (permalink)
|
|
Moderateur
Join Date: Apr 2007
Posts: 1,393
Thanks: 5
|
I prefer to use a space after things like if, before the opening parenthesis, and to keep curly brace pairs at the same indent level (Allman style). E.g.:
PHP Code:
if ($a == 1) { echo 'Hello world!'; }
The main thing, in my opinion, is to choose (or arrive at) a style and to be consistent with it rather than believing one way is any more "correct" than any other.
|
|
|
|