Commit 9612825b authored by Rejo Zenger's avatar Rejo Zenger

Language picker implemented for the larger part. Based on Jeroen Grooten's work.

parent 308359e3
......@@ -17,6 +17,9 @@ class Controller {
);
$f3->set('languages', $languages);
$f3->set('LOCALES','app/dict/');
$f3->set('LANGUAGE', $args['lang']);
// Init campaign informations
$f3->set('campaign', Api::get_campaign());
......
......@@ -15,5 +15,3 @@ DEBUG=3
;LANGUAGE='en'
; Global variables of website
LOCALES='app/dict/'
[routes]
; Main site
GET @home:/=Main->home
GET|POST @feedback:/feedback=Main->feedbackform
GET @home:/@lang=Main->home
GET|POST @feedback:/@lang/feedback=Main->feedbackform
GET|POST @call:/call/@id=Main->call
GET @contactslist:/contactslist=Main->contactslist
GET @feedbacksip:/calls/@callid=SIP->feedbacksip
GET @campaign:/campaign=Main->campaign
GET @piphone:/piphone=Main->piphone
GET @about:/about=Main->about
GET @campaign:/@lang/campaign=Main->campaign
GET @piphone:/@lang/piphone=Main->piphone
GET @about:/@lang/about=Main->about
; Fake REST API
GET /restapi/campaigns/@id=RestApi->campaign
......@@ -17,3 +17,6 @@ GET /restapi/campaigns/@id/feedback/categories=RestApi->categories
POST /restapi/campaigns/@id/feedback/add=RestApi->feedback_add
GET /restapi/campaigns/@id/arguments/@lang=RestApi->arguments
[redirects]
GET /=/en
......@@ -213,6 +213,19 @@ h4{
font-size: 90%;
line-height: 170%;
}
.languages{
margin-right: 20px;
}
.languages img {
height: 13px;
width: 23px;
display: inline-block;
margin-left: 15px;
box-shadow: 1px 1px 2px #ddd;
}
.languages li{
float: right;
}
@media only screen and (max-width: 1000px){
.is-reversed .content {
margin: 0;
......
flags/de.png

535 Bytes

flags/nl.png

407 Bytes

......@@ -3,8 +3,8 @@
<div class="container">
<div class="footer_item">
<ul>
<li><a href="/">{{ @footer.root }}</a></li>
<li><a href="/about">{{ @footer.contactcredits }}</a></li>
<li><a href="{{ 'home' | alias }}">{{ @footer.root }}</a></li>
<li><a href="{{ 'about' | alias }}">{{ @footer.contactcredits }}</a></li>
</ul>
</div>
<div class="footer_item mailinglist">
......
......@@ -23,28 +23,36 @@
<meta name="msapplication-TileImage" content="/ms-icon-144x144.png">
<meta name="theme-color" content="#ffffff">
<!-- Materialize -->
<link type="text/css" rel="stylesheet" href="/css/material-font.css">
<link type="text/css" rel="stylesheet" href="/css/material-font.css">
<link type="text/css" rel="stylesheet" href="/static/css/materialize.min.css" media="screen,projection"/>
<link type="text/css" rel="stylesheet" href="/static/css/piphone.css" media="screen,projection"/>
<!-- JS Materialize -->
<script src="/static/js/jquery-2.1.1.js"></script>
<script type="text/javascript" src="/static/js/materialize.min.js"></script>
<!-- Piwik -->
<script type="text/javascript">
var _paq = _paq || [];
// tracker methods like "setCustomDimension" should be called before "trackPageView"
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="//stats.bof.nl/";
_paq.push(['setTrackerUrl', u+'piwik.php']);
_paq.push(['setSiteId', '16']);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
})();
</script>
<!-- End Piwik Code -->
<!-- CUSTOM JS -->
<script src="/static/js/custom.js"></script>
<!-- Piwik -->
<script type="text/javascript">
var _paq = _paq || [];
// tracker methods like "setCustomDimension" should be called before "trackPageView"
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="//stats.bof.nl/";
_paq.push(['setTrackerUrl', u+'piwik.php']);
_paq.push(['setSiteId', '16']);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
})();
</script>
<!-- End Piwik Code -->
<link rel="stylesheet" href="/css/index.css">
</head>
<body>
<ul class="languages">
<li class="en"><a href="/en"><img src="/flags/en.png"></a></li>
<li class="de"><a href="/de"><img src="/flags/de.png"></a></li>
<li class="nl"><a href="/nl"><img src="/flags/nl.png"></a></li>
</ul>
<main>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment