Stack Overflow uses the jQuery framework, which has a method to show a hidden element using a simple animation, something like:
$('#notification-bar').show('slow');
http://api.jquery.com/show/ (check out the demos).
It is fixed to the top of the page using position:fixed
in CSS:
#notification-bar {
position:fixed;
top: 0px;
left: 0px;
width: 100%;
}
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…