the main reason to follow guidelines like this is to make your code legible
and modifiable.
i come to PHP from HTML via Perl/CGI, and have inherited some nasty code on
sites i have worked on. i've always appreciated code that is structurally
formatted.
Perl is notorious for its intrinsic flexiblity and default global variables,
which allows for programmers to write statements that are very hard to
comprehend while reading the code. this follows for other scripted
languages like JavaScript and PHP.
using braces and indents are a part of authoring legible code in almost any
programming language, and should be exercised whenever possible if you are
writing code that others will work on, or if you intend for your code to be
portable.
i do think that the code standard has some good elements to it, but it goes
too far to specify a 4-space indent and to specify no spaces within if
(condition) statements.
we all benefit from writing legible code, plain and simple.
DanO
-----Original Message-----
From: Mark Maggelet [mailto:[EMAIL PROTECTED]]
Sent: Friday, January 12, 2001 11:40 AM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re: [PHP] mixing HTML and PHP code
>http://www.binarycloud.com/code_standard.html
>> http://marc.theaimsgroup.com/?l=php-pear&m=97603413001842&w=2
>> Best Practices: PHP Coding Style :
>> http://phpbuilder.com/columns/tim20010101.php3
>> Smart Architectures in PHP :
>> http://phpbuilder.com/columns/tim20001010.php3
These are all just opinions, none of these are official Php style
guidelines, so there's no real reason to follow them.
- Mark
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]