Ignore:
Timestamp:
12/18/12 16:15:29 (11 years ago)
Author:
douglasz
Message:

Ticket #3236 - Correcoes para Performance: Function Within Loop Declaration.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/phpgwapi/inc/class.categories.inc.php

    r7655 r7673  
    422422                        if($self) 
    423423                        { 
    424                                 for ($i=0;$i<count($cats);++$i) 
     424                $cats_count = count($cats); 
     425                                for ($i=0;$i<$cats_count;++$i) 
    425426                                { 
    426427                                        if ($cats[$i]['id'] == $self) 
     
    467468                                if ($this->total_records > 0) 
    468469                                { 
    469                                         for ($i=0;$i<count($cats);++$i) 
     470                    $cats_count = count($cats); 
     471                                        for ($i=0;$i<$cats_count;++$i) 
    470472                                        { 
    471473                                                $image_set = '&nbsp;'; 
     
    576578                                $new_parent = $this->id2name($cat_id,'parent'); 
    577579 
    578                                 for ($i=0;$i<count($cats);++$i) 
     580                $cats_count = count($cats); 
     581                                for ($i=0;$i<$cats_count;++$i) 
    579582                                { 
    580583                                        if ($cats[$i]['level'] == 1) 
Note: See TracChangeset for help on using the changeset viewer.