Recently I was asked to add a fixed position ‘tab’ to the left side of a Facebook canvas app, for example like the Get Satisfaction ‘Community’ tab.
Normally this would be a simple case of using
position: fixed, but not in this case because Facebook canvas apps live inside iFrames. Facebook resizes this iFrame to fit its content, meaning that the main browser scrollbar is used to scroll around the page rather than the iFrame’s scrollbar. However, fixed position elements are fixed relative to the iFrame, not the main document. Since the iFrame never actually scrolls, the fixed element stays put.
1 2 3 4 5 6 7 8 9