You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

97 lines
2.5 KiB

  1. <!doctype html>
  2. <?php
  3. // parse the locale.yaml file and get the variables
  4. include "Spyc.php";
  5. $localeYaml = Spyc::YAMLLoad('locale.yaml');
  6. $lang=$_GET['lang'];
  7. // optional code for reading the accept language header
  8. /*
  9. $acceptlang='de-DE';
  10. // get the accept-language header
  11. foreach (getallheaders() as $name => $value) {
  12. if ($name == 'Accept-Language'){
  13. // echo "$name $value";
  14. $acceptlang = $value;
  15. }
  16. }
  17. echo "$acceptlang";
  18. print "oi $lang oi";
  19. */
  20. if ( in_array ($lang, array('en-US'))){
  21. $loc1 = "$lang".".utf8";
  22. $loc = $lang;
  23. }
  24. else
  25. $loc = "de-DE";
  26. //$loc = "en-US";
  27. //print "$loc $loc1";
  28. $domain = "messages";
  29. setlocale(LC_MESSAGES, $loc);
  30. setlocale(LC_ALL, $loc);
  31. $results = putenv("LC_ALL=$loc");
  32. $results = putenv("LC_MESSAGES=$loc");
  33. $results = bindtextdomain($domain,"./locale");
  34. ?>
  35. <html >
  36. <head>
  37. <title>$localeYaml['title'][$loc]</title>
  38. <meta charset="utf-8">
  39. <meta name="viewport" content="width=device-width, initial-scale=1">
  40. <!-- Kube CSS -->
  41. <link rel="stylesheet" href="css/kube.min.css">
  42. <link rel="stylesheet" href="addons/kube-addons.min.css" />
  43. <link rel="stylesheet" href="master.css" />
  44. </head>
  45. <body>
  46. <div class="page is-container">
  47. <div class="main-sidebar text-centered">
  48. <img class="wmdelogo" alt="wikimedia logo" src="Wikimedia_Deutschland-Logo.svg"/>
  49. </div>
  50. <div class="main-content">
  51. <div class="is-row" style="border:0px solid blue">
  52. <div class="is-col is-70">
  53. <?php include "form.php" ?>
  54. </div>
  55. <div class="is-col is-30">
  56. <?php echo _($localeYaml['header2_header'][$loc])?><BR>
  57. <?php echo _($localeYaml['header2_1'][$loc])?><BR>
  58. <?php echo _($localeYaml['header2_2'][$loc])?><BR>
  59. <?php echo _($localeYaml['header2_3'][$loc])?><BR>
  60. <?php echo _($localeYaml['header2_4'][$loc])?><BR>
  61. <?php echo _($localeYaml['header2_5'][$loc])?><BR>
  62. <?php echo _($localeYaml['header2_6'][$loc])?><BR><BR>
  63. <?php echo _($localeYaml['header2_note'][$loc])?><BR>
  64. </div>
  65. </div>
  66. <?php echo _($localeYaml['impressum'][$loc])?>: <a href="https://www.wikimedia.de/impressum/">https://www.wikimedia.de/impressum</a><br>
  67. <?php echo _($localeYaml['privacy'][$loc])?>: <a href="https://www.wikimedia.de/datenschutz/">https://www.wikimedia.de/datenschutz</a>
  68. </div>
  69. </div>
  70. <script src="js/kube.min.js"></script>
  71. <script src="addons/upload/kube.upload.min.js"></script>
  72. <script src="addons/kube-addons.min.js"></script>
  73. <script src="kaform.js"></script>
  74. <script src="iban.js/iban.js"></script>
  75. </body>
  76. </html>