QNimate

  • CoursesVideos
  • WP PremiumPlugins
  • DemosLab
  • Home
  • QIdea
  • QTrack
Home Carbon Ads Making HTML Underlying Elements Clickable Using pointer-events CSS Property

Making HTML Underlying Elements Clickable Using pointer-events CSS Property

When we place a HTML element above an another element then the underlying element becomes unclickable.

We can make the make the top element to bypass the mouse evenets(click, hover etc) to the underlying element using the pointer-events CSS property.

By default the value of pointer-events is auto for all elements therefore top element block mouse events for underlying elements. By making the pointer-events to “none” we can make the top elements pass the mouse events to the underlying elements.

Let’s see a demo:

Some old browsers don’t support pointer-events CSS property. In that case use the pointer-events Polyfill

Aug 4, 2014Narayan Prusty
Measure Web Page Performance Using JavaScriptSpeech Recognition and Synthesis Using JavaScript

Leave a Reply Cancel reply

To create code blocks or other preformatted text, indent by four spaces:

    This will be displayed in a monospaced font. The first four
    spaces will be stripped off, but all other whitespace
    will be preserved.
    
    Markdown is turned off in code blocks:
     [This is not a link](http://example.com)

To create not a block, but an inline code span, use backticks:

Here is some inline `code`.

For more help see http://daringfireball.net/projects/markdown/syntax

Narayan Prusty

I am a software engineer specialising in Blockchain, DevOps and Go/JavaScript. This is my personal blog where I write about things that I learn and feel interesting to share.

7 years ago Web Development
Share this
0
GooglePlus
0
Facebook
0
Twitter
0
Linkedin
Related Articles
  • Horizontal and vertical Centering Using CSS
  • Changing CSS Style using JavaScript
  • Styling First Letter And Line Using CSS
  • Understanding HTML img tag
  • Passing Objects To addEventListener
Our Sponsor
My Books

2014 - 2015 © QNimate
All tutorials MIT license