New feature: Favorites

This commit is contained in:
bergware
2023-12-27 03:47:13 +01:00
parent 058969c0dc
commit 6b7b731d31
+6 -7
View File
@@ -74,13 +74,12 @@ $task = strtok($path,'/');
if ($locale && $task=='Favorites') {
foreach(['settings','tools'] as $more) {
$text = "$docroot/languages/$locale/$more.txt";
if (file_exists($text)) {
// additional translations
$store = "$docroot/languages/$locale/$more.dot";
if (!file_exists($store)) file_put_contents($store,serialize(parse_lang_file($text)));
file_put_contents('/tmp/lang',$store."\n",FILE_APPEND);
$language = array_merge($language,unserialize(file_get_contents($store)));
}
if (!file_exists($text)) continue;
// additional translations
$store = "$docroot/languages/$locale/$more.dot";
if (!file_exists($store)) file_put_contents($store,serialize(parse_lang_file($text)));
file_put_contents('/tmp/lang',$store."\n",FILE_APPEND);
$language = array_merge($language,unserialize(file_get_contents($store)));
}
}