Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Jul 2002
    Location
    Bucharest
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    scrollbar in forms

    How can I assign a css style (scrollbar) to the whole document? I know to do this for a html page, but in the form (ex: list/menu) the scroll bar remained unchanged. I tried some JS, but it didn't work (I'm still learning).

    Thanks, Alina.

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    The Netherlands
    Posts
    217
    Thanks
    0
    Thanked 0 Times in 0 Posts
    The only,so called, CSS that changes scrollbars,is colored scrollbars in IE and Konqueror.And you can't apply it to dropdown menus,and probably it doesnt work on lists too.

  • #3
    New Coder
    Join Date
    Jun 2002
    Location
    NYC
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you define a <div> class with a fixed size using width and height in your style definition, you can use the overflow property to determine what will happen to any content that extends beyond the bounds of the <div>. The allowable options are visible, hidden, scroll and auto. Visible and hidden aren't too useful. The scroll option always leaves the scrollbars, even if the content fits within the <div>; auto only uses them if the content is too large to fit.

  • #4
    New to the CF scene
    Join Date
    Jul 2002
    Location
    Bucharest
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Ok, if the CSS doesn't work, how can I change the appearence of the scrollbar for a list/menu? JS?

  • #5
    Regular Coder
    Join Date
    Jun 2002
    Posts
    344
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Originally posted by alina
    Ok, if the CSS doesn't work, how can I change the appearence of the scrollbar for a list/menu? JS?
    You can't

    Sorry I can't offer more help, but those are the facts.

    ~Quack

  • #6
    New Coder
    Join Date
    Jun 2002
    Location
    NYC
    Posts
    30
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You can use javaScript to make any <div> move in any direction. You can trigger this movement with a onmouseDown() event. You can also define a clipping window that restricts the visible area of your layer to a fixed size. The idea is that if you trigger an upward movement of, say, 6 pixels for your layer, you simultaneously move your clipping window down 6 pixels so that the visible window stays in the same spot, but the content behind it appears to scroll up. Constructing actual scroll bars, or sliders, would be a bit more complex, but certainly do-able. It's easier to simply have an arrow up and arrow down icon, and have each trigger a function that handles the scrolling when the mouse button is pressed over it. IE has a feature called ScrollHeight that determines the actual depth of the scrolling content so you can determine when you've actually reached the bottom, and stop the scrolling. I'm not sure how it would be done in NN6, but if your content is fixed, you would simply hard code the values. It involves a lot of scripting, but if you want to customize the appearance, it's an option.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •