akf-forum/views/extra/footer.ejs

29 lines
No EOL
957 B
Text

<div class="footer">
<% if (user){ %>
<a onclick="invert()" class="btn-primary" style="color:white;"><%=(user.theme === "default" ? "black" : "default" ) + " theme!" %></a>
<script>
async function invert() {
await fetch('/api/users/<%= user.id %>', {
method: 'PATCH',
body: JSON.stringify({
theme: "<%= user.theme === `default` ? `black` : `default` %>"
}),
headers: {
"Content-Type": "application/json"
}
});
location.reload()
}
</script>
<% } %>
<a href="https://github.com/Akif9748/akf-forum" style="color: white;"> This website is powered by
<span style="color: #ffbf00;">akf-forum</span> </a>
<div>
<span style="color:white">Coders</span> <br>
<div style="text-align:center;">
By <a href="https://github.com/Akif9748/" style="color: #ffbf00;">Akif</a> <br> By <a href="#" style="color:#ffbf00;">Tokmak</a>
</div>
</div>
</div>