daviddarx daviddarx - 6 months ago 4x
HTML Question

How do I disable text selection with CSS or JavaScript?

Possible Duplicate:

CSS rule to disable text selection highlighting

I am making a HTML/CSS/jQuery gallery, with several pages.

I indeed have a "next" button, which is a simple link with a jQuery click listener.

The problem is that if the user click the button several times, the text of the button is selected, and then the full line of text. In my really darky design, that is really ugly and nonsensical.

So here is my question: Can you disable text selection on HTML?
If not, I'll terribly miss flash and its high level of configuration on textfields...

 style="-moz-user-select: none; -webkit-user-select: none; -ms-user-select:none; user-select:none;-o-user-select:none;" 
 onselectstart="return false;" 
 onmousedown="return false;">