Changeset 164


Ignore:
Timestamp:
04/26/2009 05:10:41 PM (3 years ago)
Author:
ofer
Message:

Eliminate warnings in the parser

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/WordPress/plugin/transposh/core/parser.php

    r160 r164  
    400400                { 
    401401                        //will break translation unit when one of the following characters is reached: ., 
    402                         if(($end_of_entity = is_html_entity($pos, $is_breaker))) 
     402            $end_of_entity = is_html_entity($pos, $is_breaker); 
     403                        if($end_of_entity) 
    403404                        { 
    404405                                //Check if should break - value has been set by the is_html_entity function 
     
    418419                                $start = $pos; 
    419420                        } 
    420                         else if($end_of_number = is_number($pos)) 
     421                        else if(is_number($pos)) 
    421422                        { 
    422423                                //numbers will break translations segements and will not be included in the translation 
    423424                                translate_text($start); 
    424                                 $pos = $start = $end_of_number; 
     425                                $pos = $start = is_number($pos); 
    425426                        } 
    426427                        else 
     
    465466                                $start = $pos; 
    466467                        } 
    467                         else if($end_of_number = is_number($pos)) 
     468                        else if(is_number($pos)) 
    468469                        { 
    469470                                //numbers will break translations segements and will not be included in the translation 
    470471                                translate_text($start); 
    471                                 $pos = $start = $end_of_number; 
     472                                $pos = $start = is_number($pos); 
    472473                        } 
    473474                        else 
     
    675676 * param forward - indicate direction going either backward of forward. 
    676677 */ 
    677 function skip_white_space(&$index, $forward=TRUE) 
     678function skip_white_space(&$index = NULL, $forward=TRUE) 
    678679{ 
    679680        global $page, $pos; 
     
    700701 * Return TRUE if the word matches otherwise FALSE 
    701702 */ 
    702 function is_word($word, $index1) 
     703function is_word($word, $index1 = NULL) 
    703704{ 
    704705        global $page, $pos; 
Note: See TracChangeset for help on using the changeset viewer.