SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    Cha, Cha, Cha!!! Gamermk's Avatar
    Join Date
    Aug 2005
    Posts
    604
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How to Disable Mouse Wheel?

    I've found that users in IE after selecting a dropdown will often use their mouse wheel to scroll down the page. This frequently results in their data being altered without their knowledge.

    Thus, I'd like to know if its possible to disable the mouse wheel in a specific dropdown.
    People don't read ads. They read what interests them,
    and sometimes that happens to be an ad.
    TrulyBored.com | TankingTips.com

  2. #2
    SitePoint Guru Ize's Avatar
    Join Date
    Nov 2005
    Location
    The Netherlands
    Posts
    808
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This question would be more appropriate in the Javascript forum. Disabling mouse buttons cannot be done in PHP.
    But before implementing this, consider the usability issues this might inflict. When you take away a trusted UI feature that users might rely on, your audience could get confused or frustrated.

    Just keep this in mind

  3. #3
    ✯✯✯ silver trophybronze trophy php_daemon's Avatar
    Join Date
    Mar 2006
    Posts
    5,284
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Even if it's possible, it's a wrong forum. It's a client side issue, so you should be looking for js.
    Saul

  4. #4
    Cha, Cha, Cha!!! Gamermk's Avatar
    Join Date
    Aug 2005
    Posts
    604
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Ize View Post
    This question would be more appropriate in the Javascript forum. Disabling mouse buttons cannot be done in PHP.
    But before implementing this, consider the usability issues this might inflict. When you take away a trusted UI feature that users might rely on, your audience could get confused or frustrated.

    Just keep this in mind
    Yes, agreed this should be in the JS forum. (thats what I get for posting before thinking)

    I realize that any time you disable something you are asking for trouble, and that was my same concern when asked to do this by clients that use the form, but in this case I don't think it'll be an issue.

    Edit:
    Well in case this thread makes its way to the JS forum, here's the solution I decided to use.
    Code:
    onmousewheel="window.focus(); return false;"
    I added it to the dropdowns of choice and it results in IE behaving similar to Firefox with regards to dropdowns. It doesn't allow you scroll when the dropdown has opened up with the wheel like Firefox, but that'll have to wait for another time
    Last edited by Gamermk; Jan 11, 2007 at 11:37. Reason: added my solution
    People don't read ads. They read what interests them,
    and sometimes that happens to be an ad.
    TrulyBored.com | TankingTips.com


Bookmarks

Posting Permissions

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