Fixed Sidebar during Scrolling between Header & Footer using jQuery(techbrij.com)

submitted by urenjoyurenjoy(337) 8 months, 5 days ago

It explains How to create a sidebar or section that follows you as you scroll down the page. It is very useful to show special or important content to user.

3 comments |category: |Views: 70

tags: another

new Add a live kick counter to your blog >> liveImage

You can even customize the image by choosing your own colors, and then clicking the button below to update the preview and the html code:

  • "Kick It" text
  • "Kick It" background
  • kick count text
  • kick count background
  • border

Simply copy and paste this HTML into your blog post.


Users who kicked this story:
Comments:

posted by dpetersondpeterson(4397) 8 months, 5 days ago 0

It's a nice solution, but what's the reason for using this over simple css (position: fixed)?

Reply

posted by urenjoyurenjoy(337) replied to dpetersondpeterson(4397), 8 months, 5 days ago 0

position:fixed with respect to browser window. suppose your sidebar has more items which can't be displayed in single window(see live demo) then position:fixed will hide bottom items. similarly position:fixed is not care of header and footer. if header/footer comes in sidebar area then it goes to backside of sidebar.

Reply

posted by dpetersondpeterson(4397) replied to urenjoyurenjoy(337), 8 months, 5 days ago 0

Ok so the header and footer are the reasons that you're not using position:fixed. It makes sense, I was just curious what problem you ran into that didn't allow you to go with the simplest solution.

Reply

information Login or create an account to comment on this story