Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6732269
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:37:46+00:00 2026-05-26T10:37:46+00:00

My mouse has two buttons on the side, whose default behaviour are Back and

  • 0

My mouse has two buttons on the side, whose default behaviour are “Back” and “Forward”.

What I’d like to know is whether or not it’s possible to detect clicks of these mouse buttons in JavaScript, or if these are “special” buttons akin to the keyboard’s “Play”, “Volume Up” and “Wireless on/off” buttons.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T10:37:47+00:00Added an answer on May 26, 2026 at 10:37 am

    I am not aware of any specific mouse events.

    You can, however, easily find out yourself by inspecting the event object of the mousedown event. Fullscreen fiddle: http://jsfiddle.net/dWfDL/1/show/

    var text = typeof document.body.textContent != "undefined" ? "textContent" : "innerText";
    window.onmousedown = function(e){
        //Inspect the `e` object, for example using a for(var i in e) loop, or:
        //console.log(e);
        var s = [];
        for(var i in e){
            try{
                if(e[i] !== null){
                    if(i.toUpperCase() == i) continue; //Ignore constants
                    if(typeof e[i] == "function") continue; //Ignore functions
                    if(e[i].parentNode) continue; //Ignore elements
                    if(e[i] === window) continue; //Ignore Window
                }
                s.push(i + " =\t\t" + e[i]);
            }catch(err){s.push(i + " \tERROR reading property.")}
        }
        e.preventDefault();
        s = s.join("\n") + "\n\n";
        document.body[text] = s + document.body[text];
    }
    //Double-click to wipe contents
    window.ondblclick = function(){
        document.body[text] = "";
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

If a mouse has other buttons in addition to the standard left/right/middle (e.g. forward/back),
I have built a slider that has two possible buttons: one to .toggle ,
Additionally to the regular 3 buttons my mouse has a backward & forward button
I'm having a JPanel bean which inside has two JToggle buttons.I compile and add
DataGridView.CellContentClick is not firing if I mouse click a DataGridViewCheckBoxCell very fast. How can
I would like have three mouse actions over a control: left, right and BOTH.
I have a class for mouse events. I'm using dojo b/c I like its
When a site has third party flash ads, is it possible for the site
I have a simple set of two buttons that when hovered should make a
When mouse nears top edge of scrollpane, it scrolls up until it reaches the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.