Mercurial > hg > rc2
comparison program/lib/Roundcube/rcube.php @ 5:3a5f959af5ae
debugging aids, all commented out
| author | Charlie Root |
|---|---|
| date | Thu, 30 Aug 2018 16:15:17 -0400 |
| parents | 4681f974d28b |
| children | 85a746e95663 |
comparison
equal
deleted
inserted
replaced
| 4:1ab920879b88 | 5:3a5f959af5ae |
|---|---|
| 618 | 618 |
| 619 // attrib contain text values: use them from now | 619 // attrib contain text values: use them from now |
| 620 if (($setval = $attrib[strtolower($_SESSION['language'])]) || ($setval = $attrib['en_us'])) { | 620 if (($setval = $attrib[strtolower($_SESSION['language'])]) || ($setval = $attrib['en_us'])) { |
| 621 $this->texts[$name] = $setval; | 621 $this->texts[$name] = $setval; |
| 622 } | 622 } |
| 623 | |
| 624 // check for text with domain | 623 // check for text with domain |
| 625 if ($domain && ($text = $this->texts[$domain.'.'.$name])) { | 624 if ($domain && ($text = $this->texts[$domain.'.'.$name])) { |
| 626 } | 625 } |
| 627 // text does not exist | 626 // text does not exist |
| 628 else if (!($text = $this->texts[$name])) { | 627 else if (!($text = $this->texts[$name])) { |
| 629 return "[$name]"; | 628 return "[$name]"; |
| 630 } | 629 } |
| 631 | |
| 632 // replace vars in text | 630 // replace vars in text |
| 633 if (is_array($attrib['vars'])) { | 631 if (is_array($attrib['vars'])) { |
| 634 foreach ($attrib['vars'] as $var_key => $var_value) { | 632 foreach ($attrib['vars'] as $var_key => $var_value) { |
| 635 $text = str_replace($var_key[0] != '$' ? '$'.$var_key : $var_key, $var_value, $text); | 633 $text = str_replace($var_key[0] != '$' ? '$'.$var_key : $var_key, $var_value, $text); |
| 636 } | 634 } |
| 651 } | 649 } |
| 652 | 650 |
| 653 if (isset($case_mode)) { | 651 if (isset($case_mode)) { |
| 654 $text = mb_convert_case($text, $case_mode); | 652 $text = mb_convert_case($text, $case_mode); |
| 655 } | 653 } |
| 656 | |
| 657 return $text; | 654 return $text; |
| 658 } | 655 } |
| 659 | 656 |
| 660 /** | 657 /** |
| 661 * Check if the given text label exists | 658 * Check if the given text label exists |
