diff --git a/public/javascripts/main.js b/public/javascripts/main.js index 1a1fcda..20b1d66 100644 --- a/public/javascripts/main.js +++ b/public/javascripts/main.js @@ -18,4 +18,9 @@ socket.on("logout", data=>{ }else{ window.location.href = "/"; } -}) \ No newline at end of file +}) + + +function profilRedirect(){ + document.location.href="/profil"; +} \ No newline at end of file diff --git a/views/template/navbar.pug b/views/template/navbar.pug index d738661..2da3620 100644 --- a/views/template/navbar.pug +++ b/views/template/navbar.pug @@ -2,16 +2,16 @@ extends layout block navbar if student === true - div(id="navprofile" class="student") + div(id="navprofile" class="student" onclick="profilRedirect()") p Kezel Benoit p G4S3 a(id="logout") Logout if teacher === true - div(id="navprofile" class="teacher") + div(id="navprofile" class="teacher" onclick="profilRedirect()") p Kezel Benoit a(id="logout") Logout if admin === true - div(id="navprofile" class="admin") + div(id="navprofile" class="admin" onclick="profilRedirect()") p Kezel Benoit a(id="logout") Logout