S2OJ/uoj/1/app/controllers/logout.php
2017-04-07 11:15:39 +08:00

13 lines
186 B
PHP

<?php
crsf_defend();
Auth::logout();
?>
<script type="text/javascript">
var prevUrl = document.referrer;
if (!prevUrl) {
prevUrl = '/';
};
window.location.href = prevUrl;
</script>