mirror of
https://github.com/e107inc/e107.git
synced 2025-07-30 19:30:25 +02:00
Theme content installation confirmation page added.
This commit is contained in:
@@ -324,6 +324,26 @@ class language{
|
||||
return FALSE;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Generic variable translator for LAN definitions.
|
||||
* @example $lng->translate("My name is [x] and I own a [y]", array('x'=>"John", 'y'=>"Cat"));
|
||||
*/
|
||||
function translate($lan, $array= array())
|
||||
{
|
||||
foreach($array as $k=>$v)
|
||||
{
|
||||
$search[] = "[".$k."]";
|
||||
$replace[] = "<b>".$v."</b>";
|
||||
}
|
||||
|
||||
return str_replace($search, $replace, $lan);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user