mirror of
https://github.com/mailcow/mailcow-dockerized.git
synced 2025-12-25 07:41:30 +00:00
[SOGo] Use JS for mailcow logout
This commit is contained in:
@@ -5,6 +5,16 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
window.location.href = '/user';
|
||||
}
|
||||
});
|
||||
// logout function
|
||||
function mc_logout() {
|
||||
fetch("/", {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/x-www-form-urlencoded"
|
||||
},
|
||||
body: "logout=1"
|
||||
}).then(() => window.location.href = '/');
|
||||
}
|
||||
|
||||
// Custom SOGo JS
|
||||
|
||||
|
||||
Reference in New Issue
Block a user