Need help to finish several languages?


Warning: count(): Parameter must be an array or an object that implements Countable in /home/styllloz/public_html/qa-theme/donut-theme/qa-donut-layer.php on line 274
0 like 0 dislike
14 views
Hi all. Trying to do multiple languages on the website but che did not get me
Here is what is currently done. There are 2 folders, EN and en in each folder there is a file lang.lng one Russian the other English. For example, the contents of the file lang.lng
<?php$lang = array('glav1'\t\t\t\t\t        => 'Main', 'game2' => 'Game', 'forum3' => 'Forum', 'overver4' => 'Server', ); @setlocale(LC_ALL, "EN"); ?>

In index file written
$tpl->set('{lang}', $lang);
Forth in the attached file goes as
if(!$checkLang){ $rMyLang = 'Russian'; $checkLang = 'EN'; } include SYSTEM_DIR.'/'.$checkLang.'/lang.lng';

Language it displays if you replace "EN" with @ "en" then it also changes the language.
How am I supposed to do below using the form or address has changed language?
For example there is

When you select on the form to change the language? Tried searching the Internet is scripts does not work I did not like. Can someone help how to query correctly to make or function?
by | 14 views

1 Answer

0 like 0 dislike
$checkLang = (isset($_GET['lang']) AND in_array($_GET['lang'], ['EN', 'en'])) ? $_GET['lang'] : 'EN';

Go to the page using ?lang=EN
by
110,608 questions
257,187 answers
0 comments
40,796 users