/[cvs]/nfo/php/libs/org.netfrag.flib/Application/l10n/LocaleText.php
ViewVC logotype

Diff of /nfo/php/libs/org.netfrag.flib/Application/l10n/LocaleText.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by joko, Thu Dec 19 06:18:40 2002 UTC revision 1.5 by joko, Thu Dec 19 10:30:06 2002 UTC
# Line 3  Line 3 
3  //    $Id$  //    $Id$
4  //    ------------------------------------------------------------------  //    ------------------------------------------------------------------
5  //    $Log$  //    $Log$
6    //    Revision 1.5  2002/12/19 10:30:06  joko
7    //    + argument 'newMode' for function getlt and function _getldsvar: let _getldsvar evaluate variable to still provide old behaviour/functionality
8    //
9  //    Revision 1.4  2002/12/19 06:18:40  joko  //    Revision 1.4  2002/12/19 06:18:40  joko
10  //    + '$this->site' gets used here now  //    + '$this->site' gets used here now
11  //  //
# Line 124  class LocaleText { Line 127  class LocaleText {
127      }      }
128    }    }
129        
130    function _getldsvar($ldskey, $tpl=array()) {    function _getldsvar($ldskey, $tpl=array(), $newMode = 0) {
131            
132  //print "ldskey: $ldskey<br>";  //print "ldskey: $ldskey<br>";
133    
# Line 135  class LocaleText { Line 138  class LocaleText {
138      // interpolate variable-name      // interpolate variable-name
139      $var_value = eval($eval_string);      $var_value = eval($eval_string);
140      // interpolate variable-value to do some template-vars      // interpolate variable-value to do some template-vars
141      //$var_value = eval("return \"$var_value\";");      if (!$newMode) {
142          $var_value = eval("return \"$var_value\";");
143        }
144    
145      // V1 - result interpolation using eval      // V1 - result interpolation using eval
146      // print $eval_string."<br>";      // print $eval_string."<br>";
# Line 219  class LocaleText { Line 224  class LocaleText {
224      return $this->lds;      return $this->lds;
225    }    }
226        
227    function getlt($key, $tpl=array()) {    function getlt($key, $tpl=array(), $newMode = 0) {
228      //dprint("getlt: $key");      //dprint("getlt: $key");
229      if ($ldskey = $this->_dbkey2ldskey($key)) {      if ($ldskey = $this->_dbkey2ldskey($key)) {
230        return $this->_getldsvar($ldskey, $tpl);        return $this->_getldsvar($ldskey, $tpl, $newMode);
231      }      }
232    }    }
233    

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed