Changeset 12656


Ignore:
Timestamp:
Nov 22, 2011, 10:18:15 PM (9 years ago)
Author:
rvelices
Message:

bug 2516: compiled_template_cache_language option does not work properly (again)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/template.class.php

    r12429 r12656  
    770770
    771771    $regex = "~$ldq *\'([^'$]+)\'\|@translate\|~";
    772     $source = preg_replace_callback( $regex, create_function('$m', 'global $lang; return isset($lang[$m[1]]) ? \'{\'.var_export($lang[$m[1]],true).\'|\' : \'$m[0]\';'), $source);
     772    $source = preg_replace_callback( $regex, create_function('$m', 'global $lang; return isset($lang[$m[1]]) ? \'{\'.var_export($lang[$m[1]],true).\'|\' : $m[0];'), $source);
    773773
    774774    $regex = "~($ldq *assign +var=.+ +value=)\'([^'$]+)\'\|@translate~";
    775     $source = preg_replace_callback( $regex, create_function('$m', 'global $lang; return isset($lang[$m[2]]) ? $m[1].var_export($lang[$m[2]],true) : \'$m[0]\';'), $source);
     775    $source = preg_replace_callback( $regex, create_function('$m', 'global $lang; return isset($lang[$m[2]]) ? $m[1].var_export($lang[$m[2]],true) : $m[0];'), $source);
    776776
    777777    return $source;
Note: See TracChangeset for help on using the changeset viewer.