21 lines
799 B
PHP
21 lines
799 B
PHP
|
<footer class="page-footer">
|
||
|
<div class="footer-content">
|
||
|
<p class="copyright">©2024 油二黑子站</p>
|
||
|
<div id="quoteDisplay"></div>
|
||
|
<p class="commit-id"><span class="iconfont icon-git-fenzhi-tianchong" style="font-size:15px"></span><?php echo $git_commits;?></p>
|
||
|
</div>
|
||
|
</footer>
|
||
|
<script>
|
||
|
document.addEventListener("DOMContentLoaded", function() {
|
||
|
fetch('/?api=onesay')
|
||
|
.then(response => response.json())
|
||
|
.then(data => {
|
||
|
const quoteDisplay = document.getElementById('quoteDisplay');
|
||
|
quoteDisplay.innerHTML = `<p><em>"${data.quote}"</em> —— <strong>${data.author}</strong></p>`;
|
||
|
})
|
||
|
.catch(error => console.error('Error fetching the quote:', error));
|
||
|
});
|
||
|
</script>
|
||
|
</body>
|
||
|
|
||
|
</html>
|