Disable Text Selection script
Note: Script rewritten Dec 28th, 06.
Description: This is a simple script that lets you disable text selection (the ability to drag and select text) within any element on your page, such as a certain paragraph. Script works in IE, Firefox, and Opera.
Demo: Try selecting text within the above paragraph- it's disabled.
Directions: Add this script to the HEAD section of your page:With the script installed, just call the function disableSelection(target) at the very end of the document with a reference to the element you wish to disable text within. A few examples:
Make sure to call the above functions at the end of the document to ensure the element in which to disable text for is defined before the function is called.