- This topic is empty.
Viewing 6 posts - 1 through 6 (of 6 total)
Viewing 6 posts - 1 through 6 (of 6 total)
- The forum ‘JavaScript’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Home › Forums › JavaScript › How to make a floating module, like apple/store/cart
Hi, how can I make a menu/block of CSS float on the page like this:
http://store.apple.com/us/cart
Make your browser very thin, and scroll down, the cart moves with your page. However this is NOT using just position:fixed since the cart "knows" when you are at the top and only starts to scroll after a certain distance is moved, and I see javascript being called. However their code is very mixed like spaghetti; so hard to unravel.
Any ideas? Is this a simple function in an existing JS package?
Thanks!
This article/screencast is what i believe you’re looking for.
sorry there blue, but I dont see any links in your post… thanks! ;)
http://jqueryfordesigners.com/fixed-floating-elements/
oops, I must’ve set it to display:none…. just kidding.
Excellent! thanks!!
there is a problem in that cart ..
http://jqueryfordesigners.com/fixed-floating-elements/
when you resize the browser , that cart can’t maintain its it standard position ..
see apple cart . it maintain position and you can see it also after resize of browser .