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

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

Location:
trunk/expressoMail1_2/spell_checker
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/expressoMail1_2/spell_checker/cpaint/cpaint2.backend-debugger.php

    r3400 r7655  
    7272        $scriptName = $_SERVER['SCRIPT_FILENAME']; 
    7373        $fileLines = file($scriptName); 
    74         for ($i=0; $i < sizeof($fileLines); $i++) { 
     74        for ($i=0; $i < sizeof($fileLines); ++$i) { 
    7575                $line = trim($fileLines[$i]); 
    7676                if (substr($line, 0, 9) == "FUNCTION " || substr($line,0,9) == "function ") { 
     
    7878                }                
    7979        } 
    80         for ($i = 0; $i < sizeof($match); $i++) { 
     80        for ($i = 0; $i < sizeof($match); ++$i) { 
    8181                $line = str_replace("function ", "", $match[$i]); 
    8282                $line = str_replace("FUNCTION ", "", $line); 
  • trunk/expressoMail1_2/spell_checker/cpaint/cpaint2.inc.php

    r3400 r7655  
    846846 
    847847      // now encode non-printable characters 
    848       for ($i = 0; $i < 32; $i++) { 
     848      for ($i = 0; $i < 32; ++$i) { 
    849849        $return_value = str_replace(chr($i), '\u00' . sprintf('%02x', $i), $return_value); 
    850850      } // end: for 
  • trunk/expressoMail1_2/spell_checker/cpaint/json.php

    r3400 r7655  
    126126          $s = '"'; 
    127127                 
    128           for ($i = 0; $i < $l; $i++) { 
     128          for ($i = 0; $i < $l; ++$i) { 
    129129            $c = $arg{$i}; 
    130130                     
  • trunk/expressoMail1_2/spell_checker/spell_checker.php

    r6057 r7655  
    211211 
    212212        //this loop looks through the words array and splits any lines of text that aren't html tags on space, preserving the spaces. 
    213         for($i=0; $i<$numResults; $i++){ 
     213        for($i=0; $i<$numResults; ++$i){ 
    214214                // Words alternate between real words and html tags, starting with words. 
    215215                if(($i & 1) == 0) // Even-numbered entries are word sets. 
     
    219219                        // Now go through each word and link up the misspelled ones. 
    220220                        $numWords = count($words[$i]); 
    221                         for($j=0; $j<$numWords; $j++) 
     221                        for($j=0; $j<$numWords; ++$j) 
    222222                        { 
    223223                               // $word = utf8_decode($words[$i][$j]); 
     
    242242                                            $words[$i][$j] = str_replace($tmpWord, "<span " . $onClick . " id=\"" . $varName . "_" . $misspelledCount . "_" . $tmpWord . "\" class=\"highlight\">" . stripslashes($tmpWord) . "</span>", $words[$i][$j]);  
    243243 
    244                                         $misspelledCount++; 
     244                                        ++$misspelledCount; 
    245245 
    246246                                } 
Note: See TracChangeset for help on using the changeset viewer.