Search
Learn
Share

Disable a link with CSS

Published by Profile Image DevDashboard on 14 March, 2016
171 views
To disable a link with CSS, first create the CSS class:

.disabled {
pointer-events: none;
cursor: default;
}

Then add the class disabled to a link you want to disable:

<a href="url.html" class="disabled">
My Link
</a>