admin translation: Configuration / Settings
#1
I translated all admin language files into Dutch.

Nevertheless in the administrator panel, Configuration / Settings  all elements (starting with '.Board Online / Offline') are in English.
I couldn't find the file in which the text of these elements reside.

Can someone please tell me where I can find this file ?
Reply
#2
replies here can be helpful => translate settings
Reply
#3
Thank you, but,

- my Polish is rather rusty
- several new items are lacking (not updated to version 1.8.22)
Isn't it possible to make the entries and their English contents available ?
Reply
#4
^ not sure if English language file is available with all the settings.
may be you can try using this German language file => Link
Reply
#5
I found the English version in:

:\mybb_1822\Upload\install\resources\settings.xml
Reply
#6
(2020-04-30, 02:13 PM)snb Wrote: I found the English version in:

:\mybb_1822\Upload\install\resources\settings.xml

I working on a translation too, actually I've find this

You can perform the following queries in a .php file to get most of settings and settinggroups variables (and add them in the config_settings.lang.php) :

For settinggroups
<?php
try
{
	// On se connecte à MySQL
	$bdd = new PDO('mysql:host=Your_MySQL_Host;dbname=Your_DB_Name;charset=utf8', 'USERNAME', 'PASSWORD');
}
catch(Exception $e)
{
	// En cas d'erreur, on affiche un message et on arrête tout
        die('Erreur : '.$e->getMessage());
}

// Si tout va bien, on peut continuer

// On récupère tout le contenu de la table settinggroups
$reponse = $bdd->query('SELECT * FROM mybb_settinggroups');

// On affiche chaque entrée une à une
while ($donnees = $reponse->fetch())
{
?>

$l['setting_group_<?php echo $donnees['name']; ?>'] = "<?php echo $donnees['title']; ?>";<br />
$l['setting_group_<?php echo $donnees['name']; ?>_desc'] = "<?php echo $donnees['description']; ?>";<br />

<?php
}

$reponse->closeCursor(); // Termine le traitement de la requête

?>

For settings
<?php
try
{
	// On se connecte à MySQL
	$bdd = new PDO('mysql:host=Your_MySQL_Host;dbname=Your_DB_Name;charset=utf8', 'USERNAME', 'PASSWORD');
}
catch(Exception $e)
{
	// En cas d'erreur, on affiche un message et on arrête tout
        die('Erreur : '.$e->getMessage());
}

// Si tout va bien, on peut continuer

// On récupère tout le contenu de la table settinggroups
$reponse = $bdd->query('SELECT * FROM mybb_settings');

// On affiche chaque entrée une à une
while ($donnees = $reponse->fetch())
{
?>

$l['setting_<?php echo $donnees['name']; ?>'] = "<?php echo $donnees['title']; ?>";<br />
$l['setting_<?php echo $donnees['name']; ?>_desc'] = "<?php echo $donnees['description']; ?>";<br />

<?php
}

$reponse->closeCursor(); // Termine le traitement de la requête

?>

But it's not perfect, I don't have the data from the Select and Radio options, a regex is needed and I'm not a coder, so actually I search how perform that.

Maybe someone can help for create one variable for each option find (only for select and radio) in the column optionscode from settings table

And the html tag aren't escape, they're interpreted, if I find a solution for these problems I post the solution here Wink
Reply
#7
I created the english version based on the XML-file.
See the attachment.


Attached Files
.php   config_settings.lang.php (Size: 65.81 KB / Downloads: 32)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)