Follow along with the video below to see how to install our site as a web app on your home screen.
Бележка: This feature may not be available in some browsers.
<html>
<head>
<script>
function GoAlert() {
if (confirm('click ok to pop up after 24h or cancel to go out')) {
setTimeout('GoAlert()',24*60*60*1000);
} else {
location.href='newpage.html'
}
}
</script>
</head>
<body>
<button onclick="GoAlert()">Start</button>
</body>
</html>
palex каза:Примерно така:
Код:<html> <head> <script> function GoAlert() { if (confirm('click ok to pop up after 24h or cancel to go out')) { setTimeout('GoAlert()',24*60*60*1000); } else { location.href='newpage.html' } } </script> </head> <body> <button onclick="GoAlert()">Start</button> </body> </html>