LOL! Right!  I figure that _I'm_ the one who has to
look at my code the most.  May as well leave it where
I put it, how I put it.

Thanks for the chuckle!
B

--- Kevin Stone <[EMAIL PROTECTED]> wrote:
> I believe the standards are for coding PEAR modules
> so all code is presented
> in the same style.  It really has no influence on
> the language or community
> at large.  I say code the way you feel most
> comfortable with and damb to
> anyone who complains.  :)
> -Kevin
> 
> ----- Original Message -----
> From: "ed" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, September 27, 2002 2:16 PM
> Subject: [PHP] coding standards - control structures
> 
> 
> > Hey all.  I've read the pear coding standards.
> > I assume that if php has any official coding
> standards
> >
> > then the pear standards would be them, correct?
> >
> > Anyways, the pear docs on coding standards show
> > examples of using controls structures like
> > the following:
> >
> > if ( !$var ) {
> >     do_something();
> > }
> > else {
> >     do_something_else();
> > }
> >
> > -------
> > But I really don't like putting the opening brace
> > on the same line as the control statement.
> >
> > I really prefer doing this:
> >
> > if ( $var )
> > {   do_something();
> > }
> >
> >
> > or
> >
> > if( $var )
> > {   do_something();
> > }
> > else
> > {   do_something_else();
> > }
> >
> > -------
> > Putting the opening brace one line down on the
> same
> > column that the control statement starts on seems
> to
> > give me a much better visual cue, especially when
> > dealing with nested control statements.
> >
> > Is doing it my preferred way acceptable?
> > Will my code be looked down on?
> >
> > thanks,
> > --ed
> >
> >
> > __________________________________________________
> > Do you Yahoo!?
> > New DSL Internet Access from SBC & Yahoo!
> > http://sbc.yahoo.com
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit:
> http://www.php.net/unsub.php
> >
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 


=====
Bill Farrell
Multivalue and *nix Support Specialist

Phone: (828) 667-2245
Fax:   (928) 563-5189
Web:   http://www.jwfarrell.com

__________________________________________________
Do you Yahoo!?
New DSL Internet Access from SBC & Yahoo!
http://sbc.yahoo.com

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to