Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
現在、このコードを使用してオーバーレイをトリガーしています。
<body onload="toggleOverlay();">
これをミリ秒または秒単位で設定した時間遅らせるにはどうすればよいですか?
setTimeout() を使用して、toggleOverlay() の実行を遅らせることができます。
onload="setTimeout('toggleOverlay()', 1000);
ページが読み込まれると、setTimeout が実行されますが、toggleOverlay はまだ実行されません。