Changeset 115


Ignore:
Timestamp:
03/28/2009 11:13:00 PM (3 years ago)
Author:
amir
Message:

Fix for ticket #25

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/WordPress/plugin/transposh/transposh_widget.php

    r110 r115  
    117117 
    118118                                //Only show languages which are viewable or (editable and the user is a translator) 
    119                                 if(strstr($viewable_langs, $code) || 
    120                                    ($is_translator && strstr($editable_langs, $code)) || 
     119                                if(strpos($viewable_langs, $code) !== FALSE || 
     120                                   ($is_translator && strpos($editable_langs, $code) !== FALSE) || 
    121121                                   (get_option(DEFAULT_LANG) == $code && $lang)) 
    122122                                { 
     
    150150 
    151151                //Only show languages which are viewable or (editable and the user is a translator) 
    152                                 if(strstr($viewable_langs, $code) || 
    153                                    ($is_translator && strstr($editable_langs, $code)) || 
     152                                if(strpos($viewable_langs, $code) !== FALSE || 
     153                                   ($is_translator && strpos($editable_langs, $code) !== FALSE) || 
    154154                                   (get_option(DEFAULT_LANG) == $code && $lang)) 
    155155                                { 
     
    168168    { 
    169169        //Add the edit checkbox only for translators  on languages marked as editable 
    170         if($is_translator && strstr($editable_langs, $lang)) 
     170        if($is_translator && strpos($editable_langs, $lang) !== FALSE) 
    171171        { 
    172172            echo "<input type=\"checkbox\" name=\"" . EDIT_PARAM . "\" value=\"1\"" . 
Note: See TracChangeset for help on using the changeset viewer.