答案 0 :(得分:1)
你可以使用jQuery(不一定是有用的)和JavaScript函数setTimeout 请参阅示例:
var pop = $('<div>You have gone full screen <a>Exit full screen</a></div>');
$('a', pop).click(closePop)
setTimeout(closePop, 3000)
pop.css({
padding: 10,
border: '1px solid gray',
borderRadius: 2,
display: 'inline-block',
align: 'center',
})
$('a', pop).css({
textDecoration: 'underline',
color: 'gray',
cursor: 'pointer'
})
function closePop() {
pop.slideUp()
}
$(document.body).append(pop)
&#13;
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
&#13;