csrf added to startpage and first steps to double video
This commit is contained in:
@@ -4,14 +4,49 @@
|
||||
</p>") -%}
|
||||
{% if (embed == "yt") %}
|
||||
|
||||
{% if (title != "") %}
|
||||
<h3>{{title}}</h3>
|
||||
{% endif %}
|
||||
<div class="iframe-container">
|
||||
<iframe class="center" src="{{ video_url }}" title="YouTube video player" frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
||||
allowfullscreen></iframe>
|
||||
{% if (title != "") %}
|
||||
<h3>{{title}}</h3>
|
||||
{% endif %}
|
||||
<div class="iframe-container">
|
||||
<iframe class="center" src="{{ video_url }}" title="YouTube video player" frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
||||
allowfullscreen></iframe>
|
||||
</div>
|
||||
|
||||
{% else %}
|
||||
{{code}}
|
||||
{% endif %}
|
||||
{%- endmacro %}
|
||||
|
||||
{% macro double_video(video_url1, video_url2, embed="yt", title="",width="560", height="315", class="center", code="<p>
|
||||
No code given
|
||||
</p>") -%}
|
||||
{% if (embed == "yt") %}
|
||||
|
||||
{% if (title != "") %}
|
||||
<h3>{{title}}</h3>
|
||||
{% endif %}
|
||||
<div class="double_video_container">
|
||||
|
||||
<div class="dv_half">
|
||||
<div class="iframe-container">
|
||||
<iframe class="center" src="{{ video_url1 }}" title="YouTube video player" frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
||||
allowfullscreen></iframe>
|
||||
</div>
|
||||
</div>
|
||||
<div style="display: inline-block;">
|
||||
<button class="dv_button">Play Videos</button>
|
||||
</div>
|
||||
<div class="dv_half">
|
||||
<div class="iframe-container">
|
||||
<iframe class="center" src="{{ video_url2 }}" title="YouTube video player" frameborder="0"
|
||||
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share"
|
||||
allowfullscreen></iframe>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
{% else %}
|
||||
{{code}}
|
||||
@@ -59,6 +94,8 @@ step={{question["step"]}}
|
||||
<div class="container">
|
||||
{% if (stimulus_type == "single_video") %}
|
||||
{{ single_video(**stimulus_configuration) }}
|
||||
{% elif (stimulus_type == "double_video") %}
|
||||
{{ double_video(**stimulus_configuration) }}
|
||||
{% elif (stimulus_type == "empty") %}
|
||||
|
||||
{% else %}
|
||||
@@ -66,7 +103,7 @@ step={{question["step"]}}
|
||||
{% endif %}
|
||||
|
||||
<form class="formlayout" id="question_form" action="http://localhost:5000/send_json" method="post">
|
||||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}"/>
|
||||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}" />
|
||||
{% for question in questions %}
|
||||
{% if (questions[question]["type"] == "likert") %}
|
||||
<div class="likercontainer">
|
||||
|
||||
Reference in New Issue
Block a user