Results 1 to 8 of 8
  1. blankiek's Avatar
    Posts
    83 Posts
    Global Posts
    100 Global Posts
       #1  
    Does anyone know of the html/css code that allows a box of content to stay on the side of a page, but follows the person as they scroll down the site?

    Even if you don't know a code, can you tell me the correct term for it so I can find it myself?
    Last edited by blankiek; 06/19/2010 at 08:37 PM.
  2. #2  
    It's not HTML, its CSS. You're looking for fixed positioning in CSS. Put a <div> element in your HTML code around the items you want to stay fixed, and create a class or ID in the CSS code. Be forewarned that earlier versions of IE have an issue with fixed positioning.
    Richard Neff

    My tutorials on WebOS development: Beyond 'Hello World!' | Getting Started - WebOS Development

    My apps: Percent Table | SierraPapa
  3. blankiek's Avatar
    Posts
    83 Posts
    Global Posts
    100 Global Posts
       #3  
    Quote Originally Posted by RickNeff View Post
    It's not HTML, its CSS. You're looking for fixed positioning in CSS. Put a <div> element in your HTML code around the items you want to stay fixed, and create a class or ID in the CSS code. Be forewarned that earlier versions of IE have an issue with fixed positioning.
    Thanks for the answer but I don't really do so well with CSS. (I usually get my codes online.)

    However, I cannot find one. Is it possible you can help me a little more?
  4. TyBec's Avatar
    Posts
    175 Posts
    Global Posts
    239 Global Posts
    #4  
    As an internet user, I must say that I find what your doing very annoying and web 1.0. Good luck though.
  5. #5  
    Quote Originally Posted by blankiek View Post
    Does anyone know of the html/css code that allows a box of content to stay on the side of a page, but follows the person as they scroll down the site?

    Even if you don't know a code, can you tell me the correct term for it so I can find it myself?
    It's actually Javascript that gets put into the HTML. You can copy & paste the code from a number of free javascript sites.

    Try here:

    http://www.dynamicdrive.com/dynamicindex1/staticmenu.htm
  6. #7  
    You DON'T need Javascript. Fixed positioning in CSS works fine.

    A simple search of "css fixed positioning example" brings up many results. But, 2 that I think show the concept well:
    CSS: fixed menus
    Tryit Editor v1.4

    And, I'm sorry, if you don't do CSS, then you aren't following Web standards. CSS is something you need to know if you're serious about Web development.
    Richard Neff

    My tutorials on WebOS development: Beyond 'Hello World!' | Getting Started - WebOS Development

    My apps: Percent Table | SierraPapa
  7. #8  
    Sigh. It's actually DHTML a combination of CSS and JavaScript. Many are missing the point of the question which is script for how to keep something displayed in the same position on a page even as the page is scrolled. There are numerous examples on the innerwebs.

    Annoying? There are more annoying advert methods in use.

Posting Permissions