On Sun, Mar 8, 2009 at 7:31 AM, Ashley Sheridan
a...@ashleysheridan.co.ukwrote:
On Sat, 2009-03-07 at 06:23 -0800, Michael A. Peters wrote:
Ashley Sheridan wrote:
I'm more a fan of lining up opening and closing brackets so they are at
the same indent level. It prevents one of the
On Thu, 2009-03-05 at 19:58 -0800, Michael A. Peters wrote:
PJ wrote:
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if (strlen($_POST[first_nameIN]) 0
Ashley Sheridan wrote:
On Thu, 2009-03-05 at 19:58 -0800, Michael A. Peters wrote:
PJ wrote:
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if
On Sat, 2009-03-07 at 13:42 +, Nathan Rixham wrote:
Ashley Sheridan wrote:
On Thu, 2009-03-05 at 19:58 -0800, Michael A. Peters wrote:
PJ wrote:
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
Ashley Sheridan wrote:
On Sat, 2009-03-07 at 13:42 +, Nathan Rixham wrote:
Ashley Sheridan wrote:
On Thu, 2009-03-05 at 19:58 -0800, Michael A. Peters wrote:
PJ wrote:
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
On Sat, 2009-03-07 at 14:06 +, Nathan Rixham wrote:
Ashley Sheridan wrote:
On Sat, 2009-03-07 at 13:42 +, Nathan Rixham wrote:
Ashley Sheridan wrote:
On Thu, 2009-03-05 at 19:58 -0800, Michael A. Peters wrote:
PJ wrote:
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And
Ashley Sheridan wrote:
I'm more a fan of lining up opening and closing brackets so they are at
the same indent level. It prevents one of the most popular errors caused
by omitting a bracket, brace or other in the wrong place. A few extra
line breaks in the code are not going to make a
Michael A. Peters wrote:
Ashley Sheridan wrote:
I'm more a fan of lining up opening and closing brackets so they are at
the same indent level. It prevents one of the most popular errors caused
by omitting a bracket, brace or other in the wrong place. A few extra
line breaks in the code are
Nathan Rixham wrote:
actually much of this discussion is null and voided by using a decent
IDE, certainly eclipse, netbeans, zend ide all handle much of the
formatting and indenting - the one gripe I have is that PDT2 is lacking
the format source option which is a vast time-saver when using
On Sat, Mar 07, 2009 at 02:13:11PM +, Ashley Sheridan wrote:
snip
And spaces instead of tabs! That's heresy!
No, it's python. ;-}
Paul
--
Paul M. Foster
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Sat, 2009-03-07 at 06:23 -0800, Michael A. Peters wrote:
Ashley Sheridan wrote:
I'm more a fan of lining up opening and closing brackets so they are at
the same indent level. It prevents one of the most popular errors caused
by omitting a bracket, brace or other in the wrong place. A
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if (strlen($_POST[first_nameIN]) 0 )
(strlen($_POST[last_nameIN]) 0 ) { echo $first_nameIN, ,
$last_nameIN);
else (echo error;)}
But, $first_nameIn and
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if (strlen($_POST[first_nameIN]) 0 )
(strlen($_POST[last_nameIN]) 0 ) { echo $first_nameIN, ,
$last_nameIN);
else (echo error;)}
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if (strlen($_POST[first_nameIN]) 0 )
(strlen($_POST[last_nameIN]) 0 ) { echo $first_nameIN, ,
$last_nameIN);
else (echo error;)}
But,
Are both first_nameIN AND last_nameIN longer than 0 chars?
var_dump($_POST['first_nameIN']);
var_dump($_POST['last_nameIN']);
maybe you only filled in first_name or last_name but not both.
Well,
echo $first_nameIN, , $last_nameIN;
Prints out the whole name - without the if clause; and I've
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if (strlen($_POST[first_nameIN]) 0 )
(strlen($_POST[last_nameIN]) 0 ) { echo $first_nameIN, ,
$last_nameIN);
Chris wrote:
Are both first_nameIN AND last_nameIN longer than 0 chars?
var_dump($_POST['first_nameIN']);
var_dump($_POST['last_nameIN']);
maybe you only filled in first_name or last_name but not both.
Well,
echo $first_nameIN, , $last_nameIN;
Prints out the whole name - without the if
PJ wrote:
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if (strlen($_POST[first_nameIN]) 0 )
(strlen($_POST[last_nameIN]) 0 ) { echo $first_nameIN, ,
PJ wrote:
Nathan Rixham wrote:
Chris wrote:
PJ wrote:
And again, this works:
if (strlen($_POST[first_nameIN]) == 0 ) {
$obligatoryFieldNotPresent = 1; ...
this does not:
if (strlen($_POST[first_nameIN]) 0 )
(strlen($_POST[last_nameIN]) 0 ) { echo $first_nameIN, ,
19 matches
Mail list logo