Added preference cookie

remove_Kick-In
Yuri van Midden 5 years ago
parent 70cc841610
commit ab344a9e5c
Signed by: yuri
GPG Key ID: B1E365DD233EF90A
  1. 23
      src/index.html

@ -44,6 +44,27 @@
<script src="https://cdnjs.cloudflare.com/ajax/libs/fullPage.js/3.0.2/fullpage.min.js" integrity="sha384-6yU9abmAgbGzbp5/zFigT6Ltjr3M5b0gSE6XFSO+ZMMuS1AXZlyh2tqWSVgIHRu+" crossorigin="anonymous"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/fullPage.js/3.0.2/fullpage.min.js" integrity="sha384-6yU9abmAgbGzbp5/zFigT6Ltjr3M5b0gSE6XFSO+ZMMuS1AXZlyh2tqWSVgIHRu+" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script> <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
<script type="text/javascript">
function toProductionSite() {
var name="site-preference";
var value=0;
var days=30;
var expires = "";
if (days) {
var date = new Date();
date.setTime(date.getTime() + (days*24*60*60*1000));
expires = "; expires=" + date.toUTCString();
}
document.cookie = name + "=" + (value || "") + expires + "; domain=.harambee.utwente.nl path=/";
window.location.href = "https://harambee.utwente.nl";
};
</script>
<style> <style>
p { p {
font-size: 120%; font-size: 120%;
@ -215,7 +236,7 @@
<source src="video.mp4" type="video/mp4"> <source src="video.mp4" type="video/mp4">
</video> </video>
<a href="https://harambee.utwente.nl" role="button" class="shadow regular-site btn btn-sm" aria-pressed="true"> <a href="#" onclick="toProductionSite()" role="button" class="shadow regular-site btn btn-sm" aria-pressed="true">
<i class="align-middle fas fa-rocket"></i>&nbsp; To the regular site <i class="align-middle fas fa-rocket"></i>&nbsp; To the regular site
</a> </a>

Loading…
Cancel
Save