I have found a website where the text is select protected.

How can i make this without JavaScript. I think it is possible by using CSS.

A set of paragraph is protected with non selectable contents.

But i don't know how to do.

  • 1
    Sharing your research helps everyone. Tell us what you've tried and why it didn’t meet your needs. This demonstrates that you’ve taken the time to try to help yourself, it saves us from reiterating obvious answers, and most of all it helps you get a more specific and relevant answer. Also see How to Ask – gnat Aug 6 '13 at 6:16
  • 1
    @gnat hereafter i will correct myself and will give detailed description. Thank you – nmkyuppie Aug 6 '13 at 7:02

Give Style as

.unselectable {
  -moz-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;

In HTML give as

<p class="unselectable">
Your Answer
Thanks for contributing an answer to Programmers Stack Exchange!

Please be sure to answer the question. Provide details and share your research!</p>

Now it 'll work.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.