Skip to content

Commit

Permalink
Update index.html
Browse files Browse the repository at this point in the history
  • Loading branch information
inventionpro authored Jun 27, 2024
1 parent 392d820 commit d121f1b
Showing 1 changed file with 16 additions and 9 deletions.
25 changes: 16 additions & 9 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,20 +50,25 @@ <h2>Pages:</h2>
<li>HTML (https://html.fsh.plus) <label id="html">Checking</label></li>
<li>ToDo (https://todo.fsh.plus) <label id="todo">Checking</label></li>
<li>PT (https://pt.fsh.plus) <label id="pt">Checking</label></li>
<li>Flash (https://flash.fsh.plus) <label id="flash">Checking</label></li>
<h2>Internal:</h2>
<li>Server for dynamic content <label id="sdc">Checking</label></li>
<li>Static content <label id="ssc">Checking</label></li>
<li>Dynamic content <label id="sdc">Checking</label></li>
</div>
</body>
<script>
function check(id, url) {
fetch(url).then(tt=>{
if (tt.ok){
document.getElementById(id).innerHTML = 'Online';
document.getElementById(id).classList.add('on');
} else {
document.getElementById(id).innerHTML = 'Offline';
document.getElementById(id).classList.add('off');
}})
let timer = Date.now();
fetch(url)
.then(tt=>{
if (tt.ok){
document.getElementById(id).innerHTML = 'Online ('+Date.now()-timer+'ms)';
document.getElementById(id).classList.add('on');
} else {
document.getElementById(id).innerHTML = 'Offline';
document.getElementById(id).classList.add('off');
}
})
}
check('main', 'https://fsh.plus')
check('bot', 'https://bot.fsh.plus')
Expand All @@ -75,7 +80,9 @@ <h2>Internal:</h2>
check('html', 'https://html.fsh.plus')
check('todo', 'https://todo.fsh.plus')
check('pt', 'https://pt.fsh.plus')
check('flash', 'https://flash.fsh.plus')

check('ssc', 'https://fsh-org.github.io/Fsh-plus')
check('sdc', 'https://corsproxy.io/?https%3A%2F%2Fpanel.host.hitbyathunder.xyz%2F')
</script>
</html>

0 comments on commit d121f1b

Please sign in to comment.