Changeset 6057 for trunk/expressoMail1_2


Ignore:
Timestamp:
04/27/12 09:17:30 (12 years ago)
Author:
marcosw
Message:

Ticket #2398 - Compatibilizacao com PHP-5.3 em alguns módulos do expresso

Location:
trunk/expressoMail1_2
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/expressoMail1_2/inc/class.ScriptS.inc.php

    r5509 r6057  
    588588        // Recebe o conteúdo do array; 
    589589        $lines = array(); 
    590         $lines = preg_split("/\n/", $scriptName); 
     590        $lines = preg_split('/\n/', $scriptName); 
    591591 
    592592        // Pega o tamanho da regra na primeira do script; 
  • trunk/expressoMail1_2/inc/class.SieveS.inc.php

    r5509 r6057  
    7777                    elseif (preg_match("/^\"SASL\" +\"(.*)\"/",$said,$bits)) { 
    7878                                $auth_types = $bits[1]; 
    79                                 $this->saslmethods = split(" ", $auth_types); 
     79                                $this->saslmethods = preg_split('/ /', $auth_types); 
    8080                    } 
    8181                    elseif (preg_match("/^\"SIEVE\" +\"(.*)\"/",$said,$bits)) { 
    8282                                $extensions = $bits[1]; 
    83                                 $this->extensions = split(" ", $extensions); 
     83                                $this->extensions = preg_split('/ /', $extensions); 
    8484                    } 
    8585                elseif (preg_match("/^\"STARTTLS\"/",$said)){ 
     
    9898                        if (preg_match("/SASL=\{(.+)\}/",$sasl_str,$morebits)) { 
    9999                            $auth_types = $morebits[1]; 
    100                             $this->saslmethods = split(", ", $auth_types); 
     100                            $this->saslmethods = preg_split('/, /', $auth_types); 
    101101                        }else { 
    102102                                // a bit desperate if we get here. 
  • trunk/expressoMail1_2/inc/class.ldap_functions.inc.php

    r5864 r6057  
    212212                                        $contacts_result[$i] = array(); 
    213213                                        $contacts_result[$i]["cn"] = $cn; 
    214                                         list ($contacts_result[$i]["mail"], $contacts_result[$i]["phone"], $contacts_result[$i]["mobile"], $contacts_result[$i]["uid"], $contacts_result[$i]["jpegphoto"], $contacts_result[$i]["employeenumber"], $contacts_result[$i]["ou"]) = split ('%', $info); 
     214                                        list ($contacts_result[$i]["mail"], $contacts_result[$i]["phone"], $contacts_result[$i]["mobile"], $contacts_result[$i]["uid"], $contacts_result[$i]["jpegphoto"], $contacts_result[$i]["employeenumber"], $contacts_result[$i]["ou"]) = preg_split('/%/', $info); 
    215215                                        $i++; 
    216216                                } 
     
    511511                    $extendedinfo=false; 
    512512 
    513                 list ($contacts_result["mail"], $contacts_result["phone"], $contacts_result["mobile"], $contacts_result["uid"], $contacts_result["jpegphoto"], $contacts_result["employeenumber"], $contacts_result["ou"]) = split ('%', $info); 
     513                list ($contacts_result["mail"], $contacts_result["phone"], $contacts_result["mobile"], $contacts_result["uid"], $contacts_result["jpegphoto"], $contacts_result["employeenumber"], $contacts_result["ou"]) = preg_split('/%/', $info); 
    514514 
    515515                if ($contacts_result['jpegphoto']) 
  • trunk/expressoMail1_2/spell_checker/cpaint/cpaint2.proxy.php

    r3400 r6057  
    127127    } 
    128128 
    129     list($http_headers, $http_body) = split("\r\n\r\n", $http_data, 2); 
     129    list($http_headers, $http_body) = preg_split('/\r\n\r\n/', $http_data, 2); 
    130130    echo($http_body); 
    131131    @fclose($cp_socket); 
  • trunk/expressoMail1_2/spell_checker/pspell_comp.php

    r3400 r6057  
    201201 
    202202            //parse output 
    203             $lines = split("\n",$out); 
     203            $lines = preg_split('/\n/',$out); 
    204204            foreach ($lines as $line){ 
    205205                $line = trim($line); 
     
    210210                if($line[0] == '&'){ 
    211211                    $line = preg_replace('/&.*?: /','',$line); 
    212                     return split(', ',$line); 
     212                    return preg_split('/, /',$line); 
    213213                } 
    214214            } 
  • trunk/expressoMail1_2/spell_checker/spell_checker.php

    r3400 r6057  
    197197 
    198198        //splits the string on any html tags, preserving the tags and putting them in the $words array 
    199         $words = preg_split("/(<[^<>]*>)/", $string, -1, PREG_SPLIT_DELIM_CAPTURE); 
     199        $words = preg_split('/(<[^<>]*>)/', $string, -1, PREG_SPLIT_DELIM_CAPTURE); 
    200200 
    201201        $numResults = count($words); //the number of elements in the array. 
     
    215215                if(($i & 1) == 0) // Even-numbered entries are word sets. 
    216216                { 
    217                         $words[$i] = preg_split("/(\s+|\&nbsp;)/", $words[$i], -1, PREG_SPLIT_DELIM_CAPTURE); //then split it on the spaces 
     217                        $words[$i] = preg_split('/(\s+|\&nbsp;)/', $words[$i], -1, PREG_SPLIT_DELIM_CAPTURE); //then split it on the spaces 
    218218 
    219219                        // Now go through each word and link up the misspelled ones. 
Note: See TracChangeset for help on using the changeset viewer.