disabled a click

// To disable:    
document.getElementById('id').style.pointerEvents = 'none';
// To re-enable:
document.getElementById('id').style.pointerEvents = 'auto'; 
// Use '' if you want to allow CSS rules to set the value

0
0
Noemi 130 points

                                    // CSS
.not-active {
  pointer-events: none;
  cursor: default;
  text-decoration: none;
  color: black;
}

// HTML
<a href="link.html" class="not-active">Link</a>

0
0
Are there any code examples left?
Create a Free Account
Unlock the power of data and AI by diving into Python, ChatGPT, SQL, Power BI, and beyond.
Sign up
Develop soft skills on BrainApps
Complete the IQ Test
Relative searches
disabled div from click how to disable the whole html click how to disabled onclick handle click on disabled button click disable html disabled but clickable disabled element click evnet disabled onclick disable click of a div how disable click on div hot disabled click event in <a> disable click function make element disable for click disable click disable @click click.disable disable click html disabled but clickable html disabled a after click how to disable onclick when element disabled disable click of a tag html click disable div disabled click make div disabled for click disabled click on a tag disabled click button button disabled click disabled click event how to turn off disabled after clicking button html div disable click disable div on click how to disable click on a div disabled click on div disable click on a div disable click tag a how to disable a click html how to disable a tag click how to disable click on element disable click on div how to disable html div click disabled button is also clickable disabled the click on div how to disable click on div on click disabled disable div click disable click div how to disable a click in html click on disabled element remove disabled on click anchor tag getting disbaled after certain screen size turn off location.href a link disable css disable anchor tag css add disable to a lin class disabled css click disable href angular how to diasable link in button of div angular 8 disabled ,a> tag css disable enable link possible to disable a <a> balise js html disable link how to remove the link in a href tag? disabled link in html how to disabled a tag by default style html a disabled click how to find out if the anchor tag event is disabled onclick to see if anchor element is disabled disable anchor tag in css disable clickable anchor tags active link tag and deactivate active link tag and deactivat href a href click disable css disable click on a html a tag disalbe click how to disable a tag in html anchor disable clikc a tag disabled html a tag disable css don't follow link click anchor tag disabled disable link in html ignore href register remove href using css select hyperlink that do not have attribute blank and make it opacity disable url only style as url disable a href disable link without html desabilitar link com css disabled a click
Made with love
This website uses cookies to make IQCode work for you. By using this site, you agree to our cookie policy

Welcome Back!

Sign up to unlock all of IQCode features:
  • Test your skills and track progress
  • Engage in comprehensive interactive courses
  • Commit to daily skill-enhancing challenges
  • Solve practical, real-world issues
  • Share your insights and learnings
Create an account
Sign in
Recover lost password
Or log in with

Create a Free Account

Sign up to unlock all of IQCode features:
  • Test your skills and track progress
  • Engage in comprehensive interactive courses
  • Commit to daily skill-enhancing challenges
  • Solve practical, real-world issues
  • Share your insights and learnings
Create an account
Sign up
Or sign up with
By signing up, you agree to the Terms and Conditions and Privacy Policy. You also agree to receive product-related marketing emails from IQCode, which you can unsubscribe from at any time.
Creating a new code example
Code snippet title
Source