> "Mathew" == Mathew Snyder <[EMAIL PROTECTED]> writes:
Mathew> Is there an easy way to determine if an item is in an array without
iterating
Mathew> through the array and comparing each element to the item in question?
It's a *really* good idea if you're subscribed to this list to type "per
On 12/31/2006 05:04 AM, Mathew Snyder wrote:
In the following snippet of code I'm getting the "useless use of a private
variable in a void context" error. It is at line 64 which is the closing brace
for the for loop.
for ($count; [...]
It's here, in the first instance of $count. $Count is nei
John W. Krahn wrote:
> Mathew Snyder wrote:
>> A script I've been working on will provide time spent on a work ticket in
>> H:MM
>> format. However, if the MM section is less than 10 it only shows as H:M so I
>> need to append a 0 to it. So, for instance, if the output looks like this
>> 9:7 I
Mathew Snyder wrote:
> A script I've been working on will provide time spent on a work ticket in H:MM
> format. However, if the MM section is less than 10 it only shows as H:M so I
> need to append a 0 to it. So, for instance, if the output looks like this
> 9:7 I
> need to append the 0 to the 7
A script I've been working on will provide time spent on a work ticket in H:MM
format. However, if the MM section is less than 10 it only shows as H:M so I
need to append a 0 to it. So, for instance, if the output looks like this 9:7 I
need to append the 0 to the 7 making it 9:07.
The output is
Mathew Snyder wrote:
> In the following snippet of code I'm getting the "useless use of a private
> variable in a void context" error. It is at line 64 which is the closing
> brace
> for the for loop.
>
> for ($count; $count < 7; $count++) {
^^
$count is in a void context there. Eith
Dr.Ruud wrote:
> Ken Foskey schreef:
>> Mathew Snyder:
>
>>> Is there an easy way to determine if an item is in an array without
>>> iterating through the array and comparing each element to the item
>>> in question?
>> Look up grep.
>
> That still involves iterating and comparing each element, b
Ken Foskey schreef:
> Mathew Snyder:
>> Is there an easy way to determine if an item is in an array without
>> iterating through the array and comparing each element to the item
>> in question?
>
> Look up grep.
That still involves iterating and comparing each element, but now done
(faster) by gr
Nevermind. I replaced the for loop with a while loop and it eliminated the
problem.
Mathew
Mathew Snyder wrote:
> In the following snippet of code I'm getting the "useless use of a private
> variable in a void context" error. It is at line 64 which is the closing
> brace
> for the for loop.
>
In the following snippet of code I'm getting the "useless use of a private
variable in a void context" error. It is at line 64 which is the closing brace
for the for loop.
for ($count; $count < 7; $count++) {
if ($day == '01') {
if (exists($months31{$month})){
10 matches
Mail list logo