-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathchoose_language.html
More file actions
58 lines (46 loc) · 1.64 KB
/
choose_language.html
File metadata and controls
58 lines (46 loc) · 1.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<!DOCTYPE html>
<html>
<head>
<script src="javascript/jquery-3.1.1.min.js"></script>
<script src="/assets/javascripts/jatos.js"></script>
<link rel="stylesheet" href="bootstrap-3.3.7/css/bootstrap.min.css">
<link href="static/css/forms.css" rel="stylesheet" type="text/css" media="all">
</head>
<body>
<div >
<div class="TaskCanvasContainer">
<h2 class =centered>Choisissez votre langue/Choose your language</h2>
<br>
<button class="btn btn-primary centered" id="french_button">Français </button>
<button class="btn btn-success centered" id="english_button">English</button>
</div>
</div>
</div>
<script>
function sessionSuccess(){
console.log("Succesfully sent session data");
console.log(jatos.studySessionData);
}
function sessionFailure(){
console.log("Failed to send session data");
}
function setSessionLanguage(lang){
jatos.studySessionData["language"] = lang;
}
jatos.onLoad(function () {
jatos.studySessionData.phaseComponentIndex = 6;
jatos.studySessionData.taskComponentIndex = 7;
jatos.studySessionData.questionnaireComponentIndex =8;
jatos.studySessionData.studyStartComponentIndex =10;
$("#english_button").click(function(){
setSessionLanguage("default")
jatos.startNextComponent();
});
$("#french_button").click(function(){
setSessionLanguage("fr")
jatos.startNextComponent();
});
});
</script>
</body>
</html>