How to disable selection of the text in HTML webpage without JavaScript | Easiest tutorial

preview_player
Показать описание
In this video, I will tell you how to disable selection of the text.

It is very easy to make un-selectable text without using JavaScript.

Steps:-

1) Give the id="text" to the tag you want to disable selection of text.
id="text"
2) In the style tag, write this CSS code:-
#text {
-webkit-touch-callout:none;
-webkit-user-select:none;
-khtml-user-select:none;
-moz-user-select:none;
-ms-user-select:none;
user-select:none;
}

That was very easy, right.

Comment if any doubt regarding this video.
Рекомендации по теме
welcome to shbcf.ru