2022-08-13 10:39:28 +02:00
|
|
|
<!doctype html>
|
|
|
|
<?php
|
|
|
|
|
|
|
|
|
2022-08-16 13:14:47 +02:00
|
|
|
// parse the locale.yaml file and get the variables
|
2022-08-13 10:39:28 +02:00
|
|
|
|
|
|
|
include "Spyc.php";
|
|
|
|
$localeYaml = Spyc::YAMLLoad('locale.yaml');
|
2022-08-16 13:14:47 +02:00
|
|
|
|
2022-08-13 10:39:28 +02:00
|
|
|
$lang=$_GET['lang'];
|
2022-08-16 13:14:47 +02:00
|
|
|
|
|
|
|
// optional code for reading the accept language header
|
|
|
|
|
2022-08-13 10:39:28 +02:00
|
|
|
/*
|
|
|
|
$acceptlang='de-DE';
|
|
|
|
// get the accept-language header
|
|
|
|
foreach (getallheaders() as $name => $value) {
|
|
|
|
if ($name == 'Accept-Language'){
|
|
|
|
// echo "$name $value";
|
|
|
|
$acceptlang = $value;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
echo "$acceptlang";
|
2022-08-16 13:14:47 +02:00
|
|
|
|
2022-08-13 10:39:28 +02:00
|
|
|
print "oi $lang oi";
|
|
|
|
*/
|
|
|
|
|
|
|
|
if ( in_array ($lang, array('en-US'))){
|
|
|
|
|
|
|
|
$loc1 = "$lang".".utf8";
|
|
|
|
$loc = $lang;
|
|
|
|
}
|
|
|
|
else
|
|
|
|
$loc = "de-DE";
|
|
|
|
|
2022-08-13 11:44:10 +02:00
|
|
|
//$loc = "en-US";
|
2022-08-17 13:19:40 +02:00
|
|
|
//print "$loc $loc1";
|
2022-08-13 10:39:28 +02:00
|
|
|
$domain = "messages";
|
|
|
|
|
|
|
|
setlocale(LC_MESSAGES, $loc);
|
|
|
|
setlocale(LC_ALL, $loc);
|
|
|
|
|
|
|
|
$results = putenv("LC_ALL=$loc");
|
|
|
|
$results = putenv("LC_MESSAGES=$loc");
|
2022-08-29 22:00:30 +02:00
|
|
|
//$results = bindtextdomain($domain,"./locale");
|
|
|
|
|
|
|
|
|
|
|
|
|
2022-08-13 10:39:28 +02:00
|
|
|
?>
|
|
|
|
<html >
|
|
|
|
<head>
|
2022-08-16 13:14:47 +02:00
|
|
|
<title>$localeYaml['title'][$loc]</title>
|
2022-08-13 10:39:28 +02:00
|
|
|
<meta charset="utf-8">
|
|
|
|
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
|
|
|
|
|
|
<!-- Kube CSS -->
|
|
|
|
<link rel="stylesheet" href="css/kube.min.css">
|
|
|
|
<link rel="stylesheet" href="addons/kube-addons.min.css" />
|
|
|
|
|
|
|
|
<link rel="stylesheet" href="master.css" />
|
|
|
|
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
|
|
|
|
<div class="page is-container">
|
|
|
|
<div class="main-sidebar text-centered">
|
|
|
|
<img class="wmdelogo" alt="wikimedia logo" src="Wikimedia_Deutschland-Logo.svg"/>
|
|
|
|
</div>
|
|
|
|
<div class="main-content">
|
|
|
|
<div class="is-row" style="border:0px solid blue">
|
|
|
|
<div class="is-col is-70">
|
|
|
|
<?php include "form.php" ?>
|
|
|
|
</div>
|
|
|
|
<div class="is-col is-30">
|
|
|
|
<?php
|
2022-08-13 11:44:10 +02:00
|
|
|
# $ct = @file_get_contents( "./locale/$loc/h1.php");
|
2022-08-13 10:39:28 +02:00
|
|
|
# if ($ct==false)
|
|
|
|
# $ct = file_get_contents( "h1.php");
|
|
|
|
# echo $ct;
|
|
|
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
<?php
|
2022-08-13 11:44:10 +02:00
|
|
|
$ct = @file_get_contents( "./locale/$loc/h2.php");
|
2022-08-13 10:39:28 +02:00
|
|
|
if ($ct==false)
|
|
|
|
$ct = file_get_contents( "h2.php");
|
|
|
|
echo $ct;
|
|
|
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
2022-08-29 22:00:30 +02:00
|
|
|
<?php echo $localeYaml['impressum'][$loc]?>: <a href="https://www.wikimedia.de/impressum/">https://www.wikimedia.de/impressum</a><br>
|
|
|
|
<?php echo $localeYaml['privacy'][$loc]?>: <a href="https://www.wikimedia.de/datenschutz/">https://www.wikimedia.de/datenschutz</a>
|
2022-08-13 10:39:28 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<script src="js/kube.min.js"></script>
|
2022-08-29 22:00:30 +02:00
|
|
|
<script src="kaform.js"></script>
|
2022-08-13 10:39:28 +02:00
|
|
|
<script src="addons/upload/kube.upload.min.js"></script>
|
|
|
|
<script src="addons/kube-addons.min.js"></script>
|
|
|
|
<script src="iban.js/iban.js"></script>
|
|
|
|
|
|
|
|
|
2022-08-29 22:00:30 +02:00
|
|
|
<script>
|
|
|
|
error_alert_projectid = "<?php echo $localeYaml['error_alert_projectid'][$loc]?>";
|
|
|
|
error_alert_realname = "<?php echo $localeYaml['error_alert_realname'][$loc]?>";
|
|
|
|
error_alert_email = "<?php echo $localeYaml['error_alert_email'][$loc]?>";
|
|
|
|
error_alert_iban = "<?php echo $localeYaml['error_alert_iban'][$loc]?>";
|
|
|
|
error_alert_bic = "<?php echo $localeYaml['error_alert_bic'][$loc]?>";
|
|
|
|
error_alert_paypal = "<?php echo $localeYaml['error_alert_paypal'][$loc]?>";
|
|
|
|
error_alert_expenses = "<?php echo $localeYaml['error_alert_expenses'][$loc]?>";
|
|
|
|
error_alert_agreement = "<?php echo $localeYaml['error_alert_agreement'][$loc]?>";
|
|
|
|
error_alert_ismailable = "<?php echo $localeYaml['error_alert_ismailable'][$loc]?>";
|
|
|
|
error_alert_date = "<?php echo $localeYaml['error_alert_date'][$loc]?>";
|
|
|
|
error_alert_description = "<?php echo $localeYaml['error_alert_description'][$loc]?>";
|
|
|
|
error_alert_sum = "<?php echo $localeYaml['error_alert_sum'][$loc]?>";
|
|
|
|
expenses_table_description_placeholder = "<?php echo $localeYaml['expenses_table_description_placeholder'][$loc]?>";
|
|
|
|
expenses_table_file_placeholder = "<?php echo $localeYaml['expenses_table_file_placeholder'][$loc]?>";
|
|
|
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
2022-08-13 10:39:28 +02:00
|
|
|
</body>
|
|
|
|
</html>
|