Ignore:
Timestamp:
12/14/12 14:30:35 (11 years ago)
Author:
douglasz
Message:

Ticket #3236 - Melhorias de performance no codigo do Expresso.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/calendar/inc/class.uipublicview.inc.php

    r5132 r7655  
    217217                        if($this->bo->check_perms(PHPGW_ACL_PRIVATE) == True) 
    218218                        { 
    219                                 $cols++; 
     219                                ++$cols; 
    220220                        } 
    221221 
     
    268268 
    269269                        $str = ''; 
    270                         for ($i = 0; $i < 25; $i++) 
    271                         { 
    272                                 $m++; 
     270                        for ($i = 0; $i < 25; ++$i) 
     271                        { 
     272                                ++$m; 
    273273                                if ($m > 12) 
    274274                                { 
    275275                                        $m = 1; 
    276                                         $y++; 
     276                                        ++$y; 
    277277                                } 
    278278                                $d = mktime(0,0,0,$m,1,$y); 
     
    301301 
    302302                                $str = ''; 
    303                                 for ($i = -7; $i <= 7; $i++) 
     303                                for ($i = -7; $i <= 7; ++$i) 
    304304                                { 
    305305                                        $begin = $sun + (7*24*60*60 * $i) + 12*60*60;   // we use midday, that changes in daylight-saveing does not effect us 
     
    326326 
    327327                        $str = ''; 
    328                         for ($i = ($this->bo->year - 3); $i < ($this->bo->year + 3); $i++) 
     328                        for ($i = ($this->bo->year - 3); $i < ($this->bo->year + 3); ++$i) 
    329329                        { 
    330330                                $str .= '<option value="'.$i.'"'.($i == $this->bo->year?' selected':'').'>'.$i.'</option>'."\n"; 
     
    356356                                $date_str .= '    <input type="hidden" name="year" value="'.$this->bo->year.'">'."\n"; 
    357357 
    358                                 for($i=1; $i<=6; $i++) 
     358                                for($i=1; $i<=6; ++$i) 
    359359                                { 
    360360                                        $str .= '<option value="'.$i.'"'.($i == $this->bo->num_months?' selected':'').'>'.$i.'</option>'."\n"; 
     
    521521 
    522522                        $description = $this->bo->get_short_field($event,$is_private,'description'); 
    523                         for($i=0;$i<count($picture);$i++) 
     523                        for($i=0;$i<count($picture);++$i) 
    524524                        { 
    525525                                $var = Array( 
     
    617617                        } 
    618618 
    619                         for($i=0;$i<7;$i++) 
     619                        for($i=0;$i<7;++$i) 
    620620                        { 
    621621                                $p->set_var('col_title',lang($GLOBALS['phpgw']->datetime->days[$i])); 
     
    870870                function set_week_array($startdate,$cellcolor,$weekly) 
    871871                { 
    872                         for ($j=0,$datetime=$startdate;$j<7;$j++,$datetime += 86400) 
     872                        for ($j=0,$datetime=$startdate;$j<7;++$j,$datetime += 86400) 
    873873                        { 
    874874                                $date = date('Ymd',$datetime + (60 * 60 * 2)); // +2h to be save when switching to and from dst, $datetime is alreay + TZ-Offset 
     
    946946                                if($holidays) 
    947947                                { 
    948                                         for($k=0;$k<count($holidays);$k++) 
     948                                        for($k=0;$k<count($holidays);++$k) 
    949949                                        { 
    950950                                                $holiday_name[] = $holidays[$k]['name']; 
Note: See TracChangeset for help on using the changeset viewer.