jsPsych/examples/jspsych-survey-text.html
2018-03-18 22:47:01 -04:00

28 lines
682 B
HTML

<!DOCTYPE html>
<html>
<head>
<script src="../jspsych.js"></script>
<script src="../plugins/jspsych-survey-text.js"></script>
<link rel="stylesheet" href="../css/jspsych.css"></link>
</head>
<body></body>
<script>
var survey_block = {
type: 'survey-text',
questions: [
{prompt: 'How old are you?', value: 'age', columns: 3},
{prompt: 'Where were you born?', value: 'location', columns: 50},
{prompt: 'Tell me about your day', value: 'How did it start?', rows:10, columns: 50}
]
};
jsPsych.init({
timeline: [survey_block],
on_finish: function() { jsPsych.data.displayData(); }
});
</script>
</html>