diff --git a/simpleadmin/www/ttl.html b/simpleadmin/www/ttl.html
index f0cbaa2..31694ed 100644
--- a/simpleadmin/www/ttl.html
+++ b/simpleadmin/www/ttl.html
@@ -118,17 +118,28 @@
this.ttldata = data
});
},
- setTTL() {
+ setTTL() {
fetch('/cgi-bin/set_ttl?' + new URLSearchParams({
- ttlvalue: this.newTTL,
- }))
- .then((res) => res.json())
- .then((data) => {
- this.ttldata = data
- })
- }
- }
- }
-
+ ttlvalue: this.newTTL,
+ }))
+ .then((res) => res.json())
+ .then((data) => {
+ this.ttldata = data
+ })
+ sleep(1000)
+ fetch('/cgi-bin/get_ttl_status')
+ .then((res) => res.json())
+ .then((data) => {
+ this.ttldata = data
+ });
+ }
+ }
+ function sleep(miliseconds) {
+ var currentTime = new Date().getTime();
+ while (currentTime + miliseconds >= new Date().getTime()) {
+ }
+ }
+ }
+