3 ms·
I didn't understand the absolute gif. They said use it for logos that need to appear at the top of the page, but then you see it scroll right off the screen wit
by nsxwolf 12y ago
I didn't understand the absolute gif. They said use it for logos that need to appear at the top of the page, but then you see it scroll right off the screen with the rest of it.
Are they saying, it's absolute in reference to the yellow box it's a child of, and it's only scrolling up because the yellow box is?
- spdustin 12y agoYes, it's absolute relative to its nearest positioned ancestor.
- steveax 12y agoAnd the text is just wrong: "The tricky part is that it will be absolute to the parent element that has a position of Relative or Fixed." Should be: "relative, absolute or fixed" (or more simply: position other than static")
- sandijs 12y agoThanks! Fixed!