Implemented Visitor View -- kinda betaish still

This commit is contained in:
Jeremy Zhang
2017-06-09 04:22:33 +00:00
parent 601612e436
commit 30092fde01
12 changed files with 245 additions and 60 deletions

View File

@ -7,6 +7,15 @@ $('#unauth_users').change(function() {
});
});
$('#visitor_view').change(function() {
var pathname = window.location.pathname;
var checked = $(this).is(':checked')
var payload = {"visitor_view": checked}
$.post(pathname, payload, function(data) {
Materialize.toast('Updated visitor mode setting!', 2000)
});
});
$('#chat_links').change(function() {
var pathname = window.location.pathname;
var checked = $(this).is(':checked')