By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,466 Members | 1,309 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,466 IT Pros & Developers. It's quick & easy.

How do I remove empty string elements from my array?

P: n/a
Hi,

I'm using PHP 5. I have an array of strings. What is the simplest
way to remove the elements that are empty, i.e. where the expression
"empty($elt)" returns true?

Thanks, - Dave
Nov 3 '08 #1
Share this Question
Share on Google+
36 Replies


P: n/a
la***********@zipmail.com wrote:
I'm using PHP 5. I have an array of strings. What is the simplest
way to remove the elements that are empty, i.e. where the expression
"empty($elt)" returns true?
It depends on your definition of "simple". For example, this single line
will do:

foreach($array as &$value) $value || unset($value);

However, you should ask yourself why you have empty elements in the first
place, if you don't want them.

Cheers,
--
----------------------------------
Iván Sánchez Ortega -ivan-algarroba-sanchezortega-punto-es-

286+100=386,+100=486,+100=586.00000011. Bueno... llamémosle Pentium.
Nov 3 '08 #2

P: n/a
Iván Sánchez Ortega wrote:
la***********@zipmail.com wrote:
>I'm using PHP 5. I have an array of strings. What is the simplest
way to remove the elements that are empty, i.e. where the expression
"empty($elt)" returns true?

It depends on your definition of "simple". For example, this single line
will do:

foreach($array as &$value) $value || unset($value);

However, you should ask yourself why you have empty elements in the first
place, if you don't want them.

Cheers,
Better is:

foreach ($array as $key=>$value)
if (empty($value))
unset($array[$key]);

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 3 '08 #3

P: n/a
On Mon, 03 Nov 2008 13:00:30 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>Ivn Snchez Ortega wrote:
>la***********@zipmail.com wrote:
>>I'm using PHP 5. I have an array of strings. What is the simplest
way to remove the elements that are empty, i.e. where the expression
"empty($elt)" returns true?

It depends on your definition of "simple". For example, this single line
will do:

foreach($array as &$value) $value || unset($value);

However, you should ask yourself why you have empty elements in the first
place, if you don't want them.

Cheers,

Better is:

foreach ($array as $key=>$value)
if (empty($value))
unset($array[$key]);
or:

$array = array_filter($array);

from the php docs:

--------------------------------------------------------------------------------
array array_filter ( array $input [, callback $callback ] )

If no callback is supplied, all entries of input equal to FALSE (see
converting to boolean) will be removed.
--------------------------------------------------------------------------------

Therefore empty strings will be filtered out, because they equate to
FALSE.

I have come across a situation where I wanted to remove empty strings
from an array (reading contents of a text file) and have encountered
stings of whitespace which I also wanted filtered out. In that
instance I used:

$array = array_filter(array_map('trim', $array));

HTH
Nov 3 '08 #4

P: n/a
internetwebthing wrote:
On Mon, 03 Nov 2008 13:00:30 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>Ivn Snchez Ortega wrote:
>>la***********@zipmail.com wrote:

I'm using PHP 5. I have an array of strings. What is the simplest
way to remove the elements that are empty, i.e. where the expression
"empty($elt)" returns true?
It depends on your definition of "simple". For example, this single line
will do:

foreach($array as &$value) $value || unset($value);

However, you should ask yourself why you have empty elements in the first
place, if you don't want them.

Cheers,
Better is:

foreach ($array as $key=>$value)
if (empty($value))
unset($array[$key]);

or:

$array = array_filter($array);

from the php docs:

--------------------------------------------------------------------------------
array array_filter ( array $input [, callback $callback ] )

If no callback is supplied, all entries of input equal to FALSE (see
converting to boolean) will be removed.
--------------------------------------------------------------------------------

Therefore empty strings will be filtered out, because they equate to
FALSE.

I have come across a situation where I wanted to remove empty strings
from an array (reading contents of a text file) and have encountered
stings of whitespace which I also wanted filtered out. In that
instance I used:

$array = array_filter(array_map('trim', $array));

HTH
Yes, but it could also get other entries, i.e. those which contain 0.
You need to beware of possible side effects!

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 3 '08 #5

P: n/a
On Mon, 03 Nov 2008 14:28:06 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>On Mon, 03 Nov 2008 13:00:30 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>>Ivn Snchez Ortega wrote:
la***********@zipmail.com wrote:

I'm using PHP 5. I have an array of strings. What is the simplest
way to remove the elements that are empty, i.e. where the expression
"empty($elt)" returns true?
It depends on your definition of "simple". For example, this single line
will do:

foreach($array as &$value) $value || unset($value);

However, you should ask yourself why you have empty elements in the first
place, if you don't want them.

Cheers,
Better is:

foreach ($array as $key=>$value)
if (empty($value))
unset($array[$key]);

or:

$array = array_filter($array);

from the php docs:

--------------------------------------------------------------------------------
array array_filter ( array $input [, callback $callback ] )

If no callback is supplied, all entries of input equal to FALSE (see
converting to boolean) will be removed.
--------------------------------------------------------------------------------

Therefore empty strings will be filtered out, because they equate to
FALSE.

I have come across a situation where I wanted to remove empty strings
from an array (reading contents of a text file) and have encountered
stings of whitespace which I also wanted filtered out. In that
instance I used:

$array = array_filter(array_map('trim', $array));

HTH

Yes, but it could also get other entries, i.e. those which contain 0.
You need to beware of possible side effects!
True, but not an issue for my purposes.

Nov 3 '08 #6

P: n/a
internetwebthing wrote:
On Mon, 03 Nov 2008 14:28:06 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>>On Mon, 03 Nov 2008 13:00:30 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:

Ivn Snchez Ortega wrote:
la***********@zipmail.com wrote:
>
>I'm using PHP 5. I have an array of strings. What is the simplest
>way to remove the elements that are empty, i.e. where the expression
>"empty($elt)" returns true?
It depends on your definition of "simple". For example, this single line
will do:
>
foreach($array as &$value) $value || unset($value);
>
However, you should ask yourself why you have empty elements in the first
place, if you don't want them.
>
Cheers,
Better is:

foreach ($array as $key=>$value)
if (empty($value))
unset($array[$key]);
or:

$array = array_filter($array);

from the php docs:

--------------------------------------------------------------------------------
array array_filter ( array $input [, callback $callback ] )

If no callback is supplied, all entries of input equal to FALSE (see
converting to boolean) will be removed.
--------------------------------------------------------------------------------

Therefore empty strings will be filtered out, because they equate to
FALSE.

I have come across a situation where I wanted to remove empty strings
from an array (reading contents of a text file) and have encountered
stings of whitespace which I also wanted filtered out. In that
instance I used:

$array = array_filter(array_map('trim', $array));

HTH
Yes, but it could also get other entries, i.e. those which contain 0.
You need to beware of possible side effects!

True, but not an issue for my purposes.

Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 4 '08 #7

P: n/a
On Mon, 03 Nov 2008 20:42:06 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>On Mon, 03 Nov 2008 14:28:06 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>>internetwebthing wrote:
On Mon, 03 Nov 2008 13:00:30 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:

Ivn Snchez Ortega wrote:
>la***********@zipmail.com wrote:
>>
>>I'm using PHP 5. I have an array of strings. What is the simplest
>>way to remove the elements that are empty, i.e. where the expression
>>"empty($elt)" returns true?
>It depends on your definition of "simple". For example, this single line
>will do:
>>
>foreach($array as &$value) $value || unset($value);
>>
>However, you should ask yourself why you have empty elements in the first
>place, if you don't want them.
>>
>Cheers,
Better is:
>
foreach ($array as $key=>$value)
if (empty($value))
unset($array[$key]);
or:

$array = array_filter($array);

from the php docs:

--------------------------------------------------------------------------------
array array_filter ( array $input [, callback $callback ] )

If no callback is supplied, all entries of input equal to FALSE (see
converting to boolean) will be removed.
--------------------------------------------------------------------------------

Therefore empty strings will be filtered out, because they equate to
FALSE.

I have come across a situation where I wanted to remove empty strings
from an array (reading contents of a text file) and have encountered
stings of whitespace which I also wanted filtered out. In that
instance I used:

$array = array_filter(array_map('trim', $array));

HTH

Yes, but it could also get other entries, i.e. those which contain 0.
You need to beware of possible side effects!

True, but not an issue for my purposes.


Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.
But it /is/ good, in my opinion, to suggest alternatives and discuss
them without .dismissing them out-of-hand.

YMMV
Nov 4 '08 #8

P: n/a
internetwebthing wrote:
On Mon, 03 Nov 2008 20:42:06 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>>On Mon, 03 Nov 2008 14:28:06 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:

internetwebthing wrote:
On Mon, 03 Nov 2008 13:00:30 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>
>Ivn Snchez Ortega wrote:
>>la***********@zipmail.com wrote:
>>>
>>>I'm using PHP 5. I have an array of strings. What is the simplest
>>>way to remove the elements that are empty, i.e. where the expression
>>>"empty($elt)" returns true?
>>It depends on your definition of "simple". For example, this single line
>>will do:
>>>
>>foreach($array as &$value) $value || unset($value);
>>>
>>However, you should ask yourself why you have empty elements in the first
>>place, if you don't want them.
>>>
>>Cheers,
>Better is:
>>
>foreach ($array as $key=>$value)
> if (empty($value))
> unset($array[$key]);
or:
>
$array = array_filter($array);
>
from the php docs:
>
--------------------------------------------------------------------------------
array array_filter ( array $input [, callback $callback ] )
>
If no callback is supplied, all entries of input equal to FALSE (see
converting to boolean) will be removed.
--------------------------------------------------------------------------------
>
Therefore empty strings will be filtered out, because they equate to
FALSE.
>
I have come across a situation where I wanted to remove empty strings
from an array (reading contents of a text file) and have encountered
stings of whitespace which I also wanted filtered out. In that
instance I used:
>
$array = array_filter(array_map('trim', $array));
>
HTH
>
>
>
Yes, but it could also get other entries, i.e. those which contain 0.
You need to beware of possible side effects!
True, but not an issue for my purposes.

Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.

But it /is/ good, in my opinion, to suggest alternatives and discuss
them without .dismissing them out-of-hand.

YMMV
Not unless you also discuss the problems they might cause.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 4 '08 #9

P: n/a
On Tue, 04 Nov 2008 17:24:55 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>>Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.

But it /is/ good, in my opinion, to suggest alternatives and discuss
them without .dismissing them out-of-hand.

Not unless you also discuss the problems they might cause.
Which has happened. This is a "GOOD THING".

What's not so good, IMHO, is that you also shoot me down in flames for
daring to suggest an alternative which, in your opinion, is
unsuitable.
Nov 4 '08 #10

P: n/a
Point to Jerry. InternetWebThing said:
True, but not an issue for my purposes.
Jerry gave a solid reason for not using your solution, and it can end
there...no need for bickering.

Thomas

On Nov 4, 7:02*pm, internetwebthing <s...@spam.spamwrote:
On Tue, 04 Nov 2008 17:24:55 -0500, Jerry Stuckle

<jstuck...@attglobal.netwrote:
>Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.
But it /is/ good, in my opinion, to suggest alternatives and discuss
them without .dismissing them out-of-hand.
Not unless you also discuss the problems they might cause.

Which has happened. This is a "GOOD THING".

What's not so good, IMHO, is that you also shoot me down in flames for
daring to suggest an alternative which, in your opinion, is
unsuitable.
Nov 5 '08 #11

P: n/a
On Tue, 4 Nov 2008 16:21:50 -0800 (PST), 703designs
<th**********@gmail.comwrote:
>Point to Jerry. InternetWebThing said:
>True, but not an issue for my purposes.

Jerry gave a solid reason for not using your solution,
Jerry gave a good and valid reason why my solution may not be
suitable, but not a definitive argument as to why it should never be
used. His admonishment of me for suggesting a solution which he finds
unsuitable is what I have an issue with here, not his argument against
its use.
>and it can end there...no need for bickering.
Oh I'm sorry.. I didn't realise I was keeping you awake.

Nov 5 '08 #12

P: n/a
On Nov 4, 7:42*pm, internetwebthing <s...@spam.spamwrote:
On Tue, 4 Nov 2008 16:21:50 -0800 (PST), 703designs

<thomasmal...@gmail.comwrote:
Point to Jerry. InternetWebThing said:
True, but not an issue for my purposes.
Jerry gave a solid reason for not using your solution,

Jerry gave a good and valid reason why my solution may not be
suitable, but not a definitive argument as to why it should never be
used. His admonishment of me for suggesting a solution which he finds
unsuitable is what I have an issue with here, not his argument against
its use.
and it can end there...no need for bickering.

Oh I'm sorry.. I didn't realise I was keeping you awake.
"Yes, but it could also get other entries, i.e. those which contain
0.
You need to beware of possible side effects!"

Still hunting for the adminishment.

Thomas
Nov 5 '08 #13

P: n/a
On Tue, 4 Nov 2008 16:49:26 -0800 (PST), 703designs
<th**********@gmail.comwrote:
>"Yes, but it could also get other entries, i.e. those which contain
0.
You need to beware of possible side effects!"

Still hunting for the adminishment.
Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.
This looks (and feels) like an admonishment to me.

I have two further issues with Jerry's statement:

1. I was not recommending anything, merely suggesting.

2. It is a ridiculous thing to say.

In support of issue 2 I would say that this newsgroup would not exist
if people did not suggest (or 'recommend', as Jerry seems to cosider
any suggestion) solutions which have worked for them in the past.

Good night.

Nov 5 '08 #14

P: n/a
internetwebthing wrote:
On Tue, 4 Nov 2008 16:49:26 -0800 (PST), 703designs
<th**********@gmail.comwrote:
>"Yes, but it could also get other entries, i.e. those which contain
0.
You need to beware of possible side effects!"

Still hunting for the adminishment.

Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.

This looks (and feels) like an admonishment to me.
Only after you argued this was a good solution.
I have two further issues with Jerry's statement:

1. I was not recommending anything, merely suggesting.

2. It is a ridiculous thing to say.

In support of issue 2 I would say that this newsgroup would not exist
if people did not suggest (or 'recommend', as Jerry seems to cosider
any suggestion) solutions which have worked for them in the past.

Good night.

I only take issue with bad solutions. And this is one of them.

But you don't see that, despite the reasons I gave.

Don't get so stuck on your own solution as to think it's the best way to
go.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 5 '08 #15

P: n/a
On Nov 4, 6:42*am, Jerry Stuckle <jstuck...@attglobal.netwrote:
internetwebthing wrote:
On Mon, 03 Nov 2008 14:28:06 -0500, Jerry Stuckle
<jstuck...@attglobal.netwrote:
internetwebthing wrote:
On Mon, 03 Nov 2008 13:00:30 -0500, Jerry Stuckle
<jstuck...@attglobal.netwrote:
>>Ivn Snchez Ortega wrote:
laredotorn...@zipmail.com wrote:
>>>>I'm using PHP 5. *I have an array of strings. *What is the simplest
way to remove the elements that are empty, i.e. where the expression
"empty($elt)" returns true?
It depends on your definition of "simple". For example, this singleline
will do:
>>>foreach($array as &$value) $value || unset($value);
>>>However, you should ask yourself why you have empty elements in thefirst
place, if you don't want them.
>>>Cheers,
Better is:
>>foreach ($array as $key=>$value)
* if (empty($value))
* * unset($array[$key]);
or:
>$array = array_filter($array);
>from the php docs:
>--------------------------------------------------------------------------------
array array_filter *( array $input *[, callback $callback *] )
>If no callback *is supplied, all entries of input *equal to FALSE(see
converting to boolean) will be removed.
--------------------------------------------------------------------------------
>Therefore empty strings will be filtered out, because they equate to
FALSE.
>I have come across a situation where I wanted to remove empty strings
from an array (reading contents of a text file) and have encountered
stings of whitespace which I also wanted filtered out. In that
instance I used:
>$array = array_filter(array_map('trim', $array));
>HTH
Yes, but it could also get other entries, i.e. those which contain 0.
You need to beware of possible side effects!
True, but not an issue for my purposes.

Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================
I have found Jerry Stuckle is funny!
Nov 5 '08 #16

P: n/a
On Tue, 04 Nov 2008 23:18:29 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>
I only take issue with bad solutions. And this is one of them.
Not for me it wasn't.

I made a suggestion that has worked for me.

It was discussed.

A potential issue was pointed out, which which I had no problem,
other to say that /for my own purposes/ it wasn't a problem.
>But you don't see that, despite the reasons I gave.

Don't get so stuck on your own solution as to think it's the best way to
go.
Please point me to the post where I have said that I think my solution
is the best way to go, or where I have got 'stuck on my own solution'.

As I have said several times before in this thread, I do not have a
problem with discussing suggestions - indeed that is at the very core
of what these newsgroups are about.

What I _do_ have a problem with is your suggestion that:

a) I was "recommending" my suggestion as the 'best' solution, and

b) it was "not a good idea" for me to suggest it, and

c) that I am trying to persuade others that my solution is the "best
way to go".
Nov 5 '08 #17

P: n/a
On Wed, 5 Nov 2008 00:59:26 -0800 (PST), Satyakaran
<sa********@gmail.comwrote:
>I have found Jerry Stuckle is funny!
Funny 'ha-ha', or funny 'peculiar' ?
Nov 5 '08 #18

P: n/a
internetwebthing schreef:
On Tue, 04 Nov 2008 23:18:29 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>I only take issue with bad solutions. And this is one of them.

Not for me it wasn't.

I made a suggestion that has worked for me.

It was discussed.

A potential issue was pointed out, which which I had no problem,
other to say that /for my own purposes/ it wasn't a problem.
>But you don't see that, despite the reasons I gave.

Don't get so stuck on your own solution as to think it's the best way to
go.

Please point me to the post where I have said that I think my solution
is the best way to go, or where I have got 'stuck on my own solution'.

As I have said several times before in this thread, I do not have a
problem with discussing suggestions - indeed that is at the very core
of what these newsgroups are about.

What I _do_ have a problem with is your suggestion that:

a) I was "recommending" my suggestion as the 'best' solution, and

b) it was "not a good idea" for me to suggest it, and

c) that I am trying to persuade others that my solution is the "best
way to go".

Hi internetwebting,

If you ask me, which you didn't, you are overreacting.
Jerry pointed out that your solution has a serious drawback, that's all.

You must be aware that other people will see this thread on the web, and
also your solution. If Jerry didn't give that warning they might be
temped to use your (short) solution.
The fact that in your case this is not an issue is totally beside the
point. Your solution might give problems for people with different
datasets (containing zeroes for example). SO it IS a bad solution. Period.

If you ask me, which you didn't, I would say a 'thanks for correcting
me, I was not aware of that side effect' would be more appropriate than
this rant.

Erwin Moller

--
"There are two ways of constructing a software design: One way is to
make it so simple that there are obviously no deficiencies, and the
other way is to make it so complicated that there are no obvious
deficiencies. The first method is far more difficult."
-- C.A.R. Hoare
Nov 5 '08 #19

P: n/a
On Wed, 05 Nov 2008 11:29:19 +0100, Erwin Moller
<Si******************************************@spam yourself.comwrote:
>If you ask me, which you didn't, you are overreacting.
Jerry pointed out that your solution has a serious drawback, that's all.
Will people please get it in their minds that this is NOT what I have
an issue with.
>You must be aware that other people will see this thread on the web, and
also your solution. If Jerry didn't give that warning they might be
temped to use your (short) solution.
The fact that in your case this is not an issue is totally beside the
point. Your solution might give problems for people with different
datasets (containing zeroes for example). SO it IS a bad solution. Period.
It is NOT a bad solution for the particular purpose for which I used
it, and it MAY NOT be a bad solution for others. It all depends on the
requirements.

It had been discussed. As I have said, this is a GOOD THING.
>If you ask me, which you didn't, I would say a 'thanks for correcting
me, I was not aware of that side effect' would be more appropriate than
this rant.
Again... and please can people get this into their heads... I do not
have a problem with Jerry pointing out a possible drawback to using my
suggestion, in fact I welcome it, because after all this is a Usenet
group for discussing PHP scripting - emphasis on 'discussing' there.

My suggestion was discussed. GOOD.

My suggestion was dismissed out-of-hand by Jerry because he finds it
unsuitable, and then I am acused of trying to "recommend" my
_suggestion_ as "best way to go".

Once again:
.. I made a suggestion;
.. It was discussed and a potential issue was pointed out;
I have a problem with none of this.

What I have a problem here is Jerry's attitude towards SUGGESTIONS of
which he does not approve; ie. that they should not be posted.
Nov 5 '08 #20

P: n/a
internetwebthing wrote:
On Wed, 05 Nov 2008 11:29:19 +0100, Erwin Moller
<Si******************************************@spam yourself.comwrote:
>If you ask me, which you didn't, you are overreacting.
Jerry pointed out that your solution has a serious drawback, that's all.

Will people please get it in their minds that this is NOT what I have
an issue with.
>You must be aware that other people will see this thread on the web, and
also your solution. If Jerry didn't give that warning they might be
temped to use your (short) solution.
The fact that in your case this is not an issue is totally beside the
point. Your solution might give problems for people with different
datasets (containing zeroes for example). SO it IS a bad solution. Period.

It is NOT a bad solution for the particular purpose for which I used
it, and it MAY NOT be a bad solution for others. It all depends on the
requirements.

It had been discussed. As I have said, this is a GOOD THING.
>If you ask me, which you didn't, I would say a 'thanks for correcting
me, I was not aware of that side effect' would be more appropriate than
this rant.

Again... and please can people get this into their heads... I do not
have a problem with Jerry pointing out a possible drawback to using my
suggestion, in fact I welcome it, because after all this is a Usenet
group for discussing PHP scripting - emphasis on 'discussing' there.

My suggestion was discussed. GOOD.

My suggestion was dismissed out-of-hand by Jerry because he finds it
unsuitable, and then I am acused of trying to "recommend" my
_suggestion_ as "best way to go".

Once again:
. I made a suggestion;
. It was discussed and a potential issue was pointed out;
I have a problem with none of this.

What I have a problem here is Jerry's attitude towards SUGGESTIONS of
which he does not approve; ie. that they should not be posted.
I never said that suggestions shouldn't be posted. What I did say is
that YOUR suggestion is not a good one.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 5 '08 #21

P: n/a
On Wed, 05 Nov 2008 07:35:19 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>I never said that suggestions shouldn't be posted. What I did say is
that YOUR suggestion is not a good one.
You implied that my suggestion should not have been posted.
Nov 5 '08 #22

P: n/a
internetwebthing wrote:
On Wed, 05 Nov 2008 07:35:19 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>I never said that suggestions shouldn't be posted. What I did say is
that YOUR suggestion is not a good one.

You implied that my suggestion should not have been posted.
No, I said your suggestion was not a good one, and explained why it
wasn't. Only when you argued did I point out that just because
something with such a major side effect is not a good answer for many
people.

Had you mentioned the side effect in your original post, I wouldn't have
said anything (I suspect you didn't realize this was a possible side
effect). But when I pointed out the problem with your code, you got
quite defensive. And you continue to be so.

Get over it. In over 40 years of programming, I've gotten called on
solutions which aren't good, more times than I can count. Even here in
this newsgroup. I learned long ago not to become defensive - rather to
treat it as a learning situation.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 5 '08 #23

P: n/a
On Wed, 05 Nov 2008 09:29:57 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>On Wed, 05 Nov 2008 07:35:19 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>>I never said that suggestions shouldn't be posted. What I did say is
that YOUR suggestion is not a good one.

You implied that my suggestion should not have been posted.

No, I said your suggestion was not a good one, and explained why it
wasn't. Only when you argued did I point out that just because
something with such a major side effect is not a good answer for many
people.

Had you mentioned the side effect in your original post, I wouldn't have
said anything (I suspect you didn't realize this was a possible side
effect). But when I pointed out the problem with your code, you got
quite defensive. And you continue to be so.

Get over it. In over 40 years of programming, I've gotten called on
solutions which aren't good, more times than I can count. Even here in
this newsgroup. I learned long ago not to become defensive - rather to
treat it as a learning situation.
Jerry, I am not being defensive about my code suggestion - I accepted
that there was an issue with it, but said that _for_my_own_purposes_
it was not a problem. All of this is, AFAIC, good discussion and
exactly why this newsgroup and other like it exist.

My point is NOT, as I keep having to repeat, about the substance of my
suggestion, nor about its subsequent discussion.

My point IS, as I keep having to repeat, about your implication that I
should not have posted my suggestion in the first place, because in
your opinion it is a bad suggestion.

Please stop side-stepping the issue.

Nov 5 '08 #24

P: n/a
internetwebthing schreef:
On Wed, 05 Nov 2008 09:29:57 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>>On Wed, 05 Nov 2008 07:35:19 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:

I never said that suggestions shouldn't be posted. What I did say is
that YOUR suggestion is not a good one.
You implied that my suggestion should not have been posted.
No, I said your suggestion was not a good one, and explained why it
wasn't. Only when you argued did I point out that just because
something with such a major side effect is not a good answer for many
people.

Had you mentioned the side effect in your original post, I wouldn't have
said anything (I suspect you didn't realize this was a possible side
effect). But when I pointed out the problem with your code, you got
quite defensive. And you continue to be so.

Get over it. In over 40 years of programming, I've gotten called on
solutions which aren't good, more times than I can count. Even here in
this newsgroup. I learned long ago not to become defensive - rather to
treat it as a learning situation.

Jerry, I am not being defensive about my code suggestion - I accepted
that there was an issue with it, but said that _for_my_own_purposes_
it was not a problem. All of this is, AFAIC, good discussion and
exactly why this newsgroup and other like it exist.

My point is NOT, as I keep having to repeat, about the substance of my
suggestion, nor about its subsequent discussion.

My point IS, as I keep having to repeat, about your implication that I
should not have posted my suggestion in the first place, because in
your opinion it is a bad suggestion.

Please stop side-stepping the issue.
May I suggest:

http://www.youtube.com/watch?v=teMlv3ripSM

Regards,
Erwin Moller
--
"There are two ways of constructing a software design: One way is to
make it so simple that there are obviously no deficiencies, and the
other way is to make it so complicated that there are no obvious
deficiencies. The first method is far more difficult."
-- C.A.R. Hoare
Nov 5 '08 #25

P: n/a
internetwebthing wrote:
On Wed, 05 Nov 2008 09:29:57 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>>On Wed, 05 Nov 2008 07:35:19 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:

I never said that suggestions shouldn't be posted. What I did say is
that YOUR suggestion is not a good one.
You implied that my suggestion should not have been posted.
No, I said your suggestion was not a good one, and explained why it
wasn't. Only when you argued did I point out that just because
something with such a major side effect is not a good answer for many
people.

Had you mentioned the side effect in your original post, I wouldn't have
said anything (I suspect you didn't realize this was a possible side
effect). But when I pointed out the problem with your code, you got
quite defensive. And you continue to be so.

Get over it. In over 40 years of programming, I've gotten called on
solutions which aren't good, more times than I can count. Even here in
this newsgroup. I learned long ago not to become defensive - rather to
treat it as a learning situation.

Jerry, I am not being defensive about my code suggestion - I accepted
that there was an issue with it, but said that _for_my_own_purposes_
it was not a problem. All of this is, AFAIC, good discussion and
exactly why this newsgroup and other like it exist.

My point is NOT, as I keep having to repeat, about the substance of my
suggestion, nor about its subsequent discussion.

My point IS, as I keep having to repeat, about your implication that I
should not have posted my suggestion in the first place, because in
your opinion it is a bad suggestion.

Please stop side-stepping the issue.

No, I am not side-stepping the issue. Your point is off-base, because I
never implied you should not have posted your suggestion.

That's where you're off base. You are putting words into my post that I
never wrote.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 5 '08 #26

P: n/a
On Wed, 05 Nov 2008 11:06:37 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>No, I am not side-stepping the issue. Your point is off-base, because I
never implied you should not have posted your suggestion.
Would you please explain, then, what you meant by this:

Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.
>That's where you're off base. You are putting words into my post that I
never wrote.
Something which you have been doing to me all along.

Nov 5 '08 #27

P: n/a
internetwebthing wrote:
On Wed, 05 Nov 2008 11:06:37 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>No, I am not side-stepping the issue. Your point is off-base, because I
never implied you should not have posted your suggestion.

Would you please explain, then, what you meant by this:

Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.
>That's where you're off base. You are putting words into my post that I
never wrote.

Something which you have been doing to me all along.

Yes, only after you argued that your "method" worked.

But I never said you should not have posted your answer. It's just not
a good recommendation - for the solid reason I pointed out.

Again - if you would have discussed the huge potential problem your
method would have solved, or not argued about your method being correct,
I would not have said anything further.

And not once did I ever put words into your mouth.

Grow up.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 5 '08 #28

P: n/a
On Wed, 05 Nov 2008 13:57:38 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>On Wed, 05 Nov 2008 11:06:37 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>>No, I am not side-stepping the issue. Your point is off-base, because I
never implied you should not have posted your suggestion.

Would you please explain, then, what you meant by this:

>Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.
>>That's where you're off base. You are putting words into my post that I
never wrote.

Something which you have been doing to me all along.

Yes, only after you argued that your "method" worked.
Yes? You agree that you have been putting words into my posts that I
never wrote?
>But I never said you should not have posted your answer. It's just not
a good recommendation - for the solid reason I pointed out.
It was not a recommendation; it was a suggestion.
>Again - if you would have discussed the huge potential problem your
method would have solved, or not argued about your method being correct,
Hang on there just one second... I did discuss the potential problem
which you so kindly pointed out - I agreed with you. At no time have I
said that my method was "correct", only that it WORKED FOR ME.
>And not once did I ever put words into your mouth.
You agreed that you had earlier on; or rather that you were "putting
words into my posts which I never wrote".

You have said:

[quote 1]
Just because it's not an issue for your purposes does not
mean it's a good idea to recommend it to someone else.
[/quote 1]

Response: I did not recommend, I suggested. And if you're saying that
it's not a good idea to suggest it, then I take that as saying that
it's not a good idea to post the suggestion, which is in effect
implying that I should not have posted.

Question to you: How would you interpret this?

[quote 2]
Don't get so stuck on your own solution as to think it's the
best way to go.
[/quote 2]

Response: After having pointed out that my issue had nothing to do
with my suggestion, or its merits (or lack of), you are still accusing
me of doing this.

Question to you: Where is the post where I have suggested that my
method was the best way to go?

All through this thread you have consistently failed to point me to
where I have said or done any of the things of which you accuse me.
You have also attempted to subtly move the goal posts whenever I point
out flaws in your arguments.

There are two explicit questions above; please would you answer them
directly?

Nov 5 '08 #29

P: n/a
And me without popcorn...*sigh
Nov 5 '08 #30

P: n/a
internetwebthing wrote:
On Wed, 05 Nov 2008 13:57:38 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>>On Wed, 05 Nov 2008 11:06:37 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:

No, I am not side-stepping the issue. Your point is off-base, because I
never implied you should not have posted your suggestion.
Would you please explain, then, what you meant by this:

>>Just because it's not an issue for your purposes does not mean it's a
good idea to recommend it to someone else.

That's where you're off base. You are putting words into my post that I
never wrote.
Something which you have been doing to me all along.
Yes, only after you argued that your "method" worked.

Yes? You agree that you have been putting words into my posts that I
never wrote?
>But I never said you should not have posted your answer. It's just not
a good recommendation - for the solid reason I pointed out.

It was not a recommendation; it was a suggestion.
In a newsgroup, there is no difference. And you did it without warnoing
of the possible consequences.
>Again - if you would have discussed the huge potential problem your
method would have solved, or not argued about your method being correct,

Hang on there just one second... I did discuss the potential problem
which you so kindly pointed out - I agreed with you. At no time have I
said that my method was "correct", only that it WORKED FOR ME.
Yes, at the same time that you argued that your solution was a good one.
>And not once did I ever put words into your mouth.

You agreed that you had earlier on; or rather that you were "putting
words into my posts which I never wrote".

You have said:

[quote 1]
Just because it's not an issue for your purposes does not
mean it's a good idea to recommend it to someone else.
[/quote 1]

Response: I did not recommend, I suggested. And if you're saying that
it's not a good idea to suggest it, then I take that as saying that
it's not a good idea to post the suggestion, which is in effect
implying that I should not have posted.
In a newsgroup there is no difference. And you did it without warning
of the possible consequences.
Question to you: How would you interpret this?

[quote 2]
Don't get so stuck on your own solution as to think it's the
best way to go.
[/quote 2]

Response: After having pointed out that my issue had nothing to do
with my suggestion, or its merits (or lack of), you are still accusing
me of doing this.
Because that's exactly where you are. You are so stuck on your own
solution that you think it's the best way to go. Otherwise you wouldn't
be arguing so strongly.
Question to you: Where is the post where I have suggested that my
method was the best way to go?
You posted it in here in the newsgroup with no caveats.
All through this thread you have consistently failed to point me to
where I have said or done any of the things of which you accuse me.
You have also attempted to subtly move the goal posts whenever I point
out flaws in your arguments.

There are two explicit questions above; please would you answer them
directly?

You can't read, can you?

You are COMPLETELY hopeless. I've told you, and others have told you
why your "solution" is bad. Yet you continue to argue.

You're not worth any more of my time. I have better things to do. Like
help people who WANT help with GOOD answers.
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================

Nov 5 '08 #31

P: n/a
On Wed, 05 Nov 2008 15:49:34 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
>internetwebthing wrote:
>On Wed, 05 Nov 2008 13:57:38 -0500, Jerry Stuckle
<js*******@attglobal.netwrote:
[snip]
>>>>That's where you're off base. You are putting words into my post that I
never wrote.
Something which you have been doing to me all along.

Yes, only after you argued that your "method" worked.

Yes? You agree that you have been putting words into my posts that I
never wrote?
No answer to this?
>>But I never said you should not have posted your answer. It's just not
a good recommendation - for the solid reason I pointed out.

It was not a recommendation; it was a suggestion.

In a newsgroup, there is no difference. And you did it without warnoing
of the possible consequences.
You pointed out the possible consequences. I agreed with you - there
was a discussion about it - you may be surprised to learn that this is
often how usenet works.

I wonder how many other people, possibly youself included, have posted
a suggestion without also including, in that very same post, every
possible consequence?
>>Again - if you would have discussed the huge potential problem your
method would have solved, or not argued about your method being correct,

Hang on there just one second... I did discuss the potential problem
which you so kindly pointed out - I agreed with you. At no time have I
said that my method was "correct", only that it WORKED FOR ME.

Yes, at the same time that you argued that your solution was a good one.
Where did I argue that my solution was a good one? Once again, I ask
that you please point me to a post where I have said this.
>>And not once did I ever put words into your mouth.

You agreed that you had earlier on; or rather that you were "putting
words into my posts which I never wrote".

You have said:

[quote 1]
Just because it's not an issue for your purposes does not
mean it's a good idea to recommend it to someone else.
[/quote 1]

Response: I did not recommend, I suggested. And if you're saying that
it's not a good idea to suggest it, then I take that as saying that
it's not a good idea to post the suggestion, which is in effect
implying that I should not have posted.

In a newsgroup there is no difference. And you did it without warning
of the possible consequences.
You pointed out the possible consequences. I agreed with you - there
was a discussion about it - you may be surprised to learn that this is
often how usenet works.

I wonder how many other people, possibly youself included, have posted
a suggestion without also including, in that very same post, every
possible consequence?
>Question to you: How would you interpret this?

[quote 2]
Don't get so stuck on your own solution as to think it's the
best way to go.
[/quote 2]

Response: After having pointed out that my issue had nothing to do
with my suggestion, or its merits (or lack of), you are still accusing
me of doing this.

Because that's exactly where you are. You are so stuck on your own
solution that you think it's the best way to go. Otherwise you wouldn't
be arguing so strongly.
Once again, please point me to a post where I have said that my
solution was the best way to go.

You have no idea about why I am arguing. I have tried to impart clue
to you, but you still refuse to see it.
>Question to you: Where is the post where I have suggested that my
method was the best way to go?

You posted it in here in the newsgroup with no caveats.
And this suggests that I was saying my method was the best?
>All through this thread you have consistently failed to point me to
where I have said or done any of the things of which you accuse me.
You have also attempted to subtly move the goal posts whenever I point
out flaws in your arguments.

There are two explicit questions above; please would you answer them
directly?

You can't read, can you?
Yes I can. Quite clearly I can read - I read your responses, I find
issue with them and I ask you questions.

You consistently refuse to answer my questions, but still you continue
to "put words into posts which I never said".
>You are COMPLETELY hopeless. I've told you, and others have told you
why your "solution" is bad. Yet you continue to argue.
I am not arguing about my solution. I am arguing about your attitude.
>You're not worth any more of my time. I have better things to do. Like
help people who WANT help with GOOD answers.
I have tried to be civil throught this thread, and I have tried to
explain what my issue was. You are choosing to ignore that, or maybe
you are just unable to follow a logical argument.

You, sir, are a rude, arrogant, self-important, self-righteous twit.

Nov 5 '08 #32

P: n/a
On Nov 5, 4:56*pm, internetwebthing <s...@spam.spamwrote:
On Wed, 05 Nov 2008 15:49:34 -0500, Jerry Stuckle

<jstuck...@attglobal.netwrote:
internetwebthing wrote:
On Wed, 05 Nov 2008 13:57:38 -0500, Jerry Stuckle
<jstuck...@attglobal.netwrote:

[snip]
>>>That's where you're off base. *You are putting words into my postthat I
never wrote.
Something which you have been doing to me all along.
>Yes, only after you argued that your "method" worked.
Yes? You agree that you have been putting words into my posts that I
never wrote?

No answer to this?
>But I never said you should not have posted your answer. *It's justnot
a good recommendation - for the solid reason I pointed out.
It was not a recommendation; it was a suggestion.
In a newsgroup, there is no difference. *And you did it without warnoing
of the possible consequences.

You pointed out the possible consequences. I agreed with you - there
was a discussion about it - you may be surprised to learn that this is
often how usenet works.

I wonder how many other people, possibly youself included, have posted
a suggestion without also including, in that very same post, every
possible consequence?
>Again - if you would have discussed the huge potential problem your
method would have solved, or not argued about your method being correct,
Hang on there just one second... I did discuss the potential problem
which you so kindly pointed out - I agreed with you. At no time have I
said that my method was "correct", only that it WORKED FOR ME.
Yes, at the same time that you argued that your solution was a good one.

Where did I argue that my solution was a good one? Once again, I ask
that you please point me to a post where I have said this.
>And not once did I ever put words into your mouth.
You agreed that you had earlier on; or rather that you were "putting
words into my posts which I never wrote".
You have said:
[quote 1]
* * Just because it's not an issue for your purposes does not
* * mean it's a good idea to recommend it to someone else.
[/quote 1]
Response: I did not recommend, I suggested. And if you're saying that
it's not a good idea to suggest it, then I take that as saying that
it's not a good idea to post the suggestion, which is in effect
implying that I should not have posted.
In a newsgroup there is no difference. *And you did it without warning
of the possible consequences.

You pointed out the possible consequences. I agreed with you - there
was a discussion about it - you may be surprised to learn that this is
often how usenet works.

I wonder how many other people, possibly youself included, have posted
a suggestion without also including, in that very same post, every
possible consequence?
Question to you: How would you interpret this?
[quote 2]
* * Don't get so stuck on your own solution as to think it's the
* * best way to go.
[/quote 2]
Response: After having pointed out that my issue had nothing to do
with my suggestion, or its merits (or lack of), you are still accusing
me of doing this.
Because that's exactly where you are. *You are so stuck on your own
solution that you think it's the best way to go. *Otherwise you wouldn't
be arguing so strongly.

Once again, please point me to a post where I have said that my
solution was the best way to go.

You have no idea about why I am arguing. I have tried to impart clue
to you, but you still refuse to see it.
Question to you: Where is the post where I have suggested that my
method was the best way to go?
You posted it in here in the newsgroup with no caveats.

And this suggests that I was saying my method was the best?
All through this thread you have consistently failed to point me to
where I have said or done any of the things of which you accuse me.
You have also attempted to subtly move the goal posts whenever I point
out flaws in your arguments.
There are two explicit questions above; please would you answer them
directly?
You can't read, can you?

Yes I can. Quite clearly I can read - I read your responses, I find
issue with them and I ask you questions.

You consistently refuse to answer my questions, but still you continue
to "put words into posts which I never said".
You are COMPLETELY hopeless. *I've told you, and others have told you
why your "solution" is bad. *Yet you continue to argue.

I am not arguing about my solution. I am arguing about your attitude.
You're not worth any more of my time. *I have better things to do. *Like
help people who WANT help with GOOD answers.

I have tried to be civil throught this thread, and I have tried to
explain what my issue was. You are choosing to ignore that, or maybe
you are just unable to follow a logical argument.

You, sir, are a rude, arrogant, self-important, self-righteous twit.
Holy crap, this is still going on?
You, sir, are a rude, arrogant, self-important, self-righteous twit.
"sir" -- At least you addressed him respectfully, right? To quote Jack
Nicholson in "As Good As it Gets": "Last word freak."

Thomas
Nov 6 '08 #33

P: n/a
On Wed, 5 Nov 2008 16:58:23 -0800 (PST), 703designs
<th**********@gmail.comwrote:
>You, sir, are a rude, arrogant, self-important, self-righteous twit.

"sir" -- At least you addressed him respectfully, right? To quote Jack
Nicholson in "As Good As it Gets": "Last word freak."
Damn. I forgot to include 'ignorant' in that list of attributes.

I should never have posted that without the caveat that it may be
incomplete, or that some users may find it unsuitable, objectionable,
or just offensive.

My bad.

Nov 6 '08 #34

P: n/a
internetwebthing wrote:
On Wed, 5 Nov 2008 16:58:23 -0800 (PST), 703designs
<th**********@gmail.comwrote:
>>You, sir, are a rude, arrogant, self-important, self-righteous twit.
"sir" -- At least you addressed him respectfully, right? To quote Jack
Nicholson in "As Good As it Gets": "Last word freak."

Damn. I forgot to include 'ignorant' in that list of attributes.

I should never have posted that without the caveat that it may be
incomplete, or that some users may find it unsuitable, objectionable,
or just offensive.

My bad.
No, actually you left with some dignity before now, you had to come back
and stir the pot some more and remove all dignity.

Why not just leave well enough alone?

(now I have to pop more popcorn)

Scotty

Nov 6 '08 #35

P: n/a
On Nov 6, 8:32*am, FutureShock <futuresho...@att.netwrote:
internetwebthing wrote:
On Wed, 5 Nov 2008 16:58:23 -0800 (PST), 703designs
<thomasmal...@gmail.comwrote:
>You, sir, are a rude, arrogant, self-important, self-righteous twit.
"sir" -- At least you addressed him respectfully, right? To quote Jack
Nicholson in "As Good As it Gets": "Last word freak."
Damn. I forgot to include 'ignorant' in that list of attributes.
I should never have posted that without the caveat that it may be
incomplete, or that some users may find it unsuitable, objectionable,
or just offensive.
My bad.

No, actually you left with some dignity before now, you had to come back
and stir the pot some more and remove all dignity.

Why not just leave well enough alone?

(now I have to pop more popcorn)

Scotty
AH HA! But earlier, you said, "And me without popcorn...*sigh"

You, sir, are a rude, arrogant, self-important, self-righteous
twit :^)

Thomas
Nov 6 '08 #36

P: n/a
703designs wrote:
On Nov 6, 8:32 am, FutureShock <futuresho...@att.netwrote:
>internetwebthing wrote:
>>On Wed, 5 Nov 2008 16:58:23 -0800 (PST), 703designs
<thomasmal...@gmail.comwrote:
You, sir, are a rude, arrogant, self-important, self-righteous twit.
"sir" -- At least you addressed him respectfully, right? To quote Jack
Nicholson in "As Good As it Gets": "Last word freak."
Damn. I forgot to include 'ignorant' in that list of attributes.
I should never have posted that without the caveat that it may be
incomplete, or that some users may find it unsuitable, objectionable,
or just offensive.
My bad.
No, actually you left with some dignity before now, you had to come back
and stir the pot some more and remove all dignity.

Why not just leave well enough alone?

(now I have to pop more popcorn)

Scotty

AH HA! But earlier, you said, "And me without popcorn...*sigh"

You, sir, are a rude, arrogant, self-important, self-righteous
twit :^)

Thomas
And you sir forgot 'ignorant'. :)
Nov 7 '08 #37

This discussion thread is closed

Replies have been disabled for this discussion.