document.getSelection()
.. many many bookmarklets use this, as do wysiwig textarea
doo-hickies
-----Original Message-----
From: rails-spinoffs-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@xxxxxxxxxxxxxxxx
[mailto:rails-spinoffs-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@xxxxxxxxxxxxxxxx]On
Behalf Of David
Teare
Sent:
Wednesday, 30 November 2005 10:19 AM
To: rails-spinoffs@xxxxxxxxxxxxxxxxxxxxx
Subject: [Rails-spinoffs] OT - Detect selected text with
_javascript_
Hello,
Does anyone know if it is possible for _javascript_ to detect
what text
is currently selected by a
user? I would like to allow the user to
select some text and then grab that text using JS.
I saw these guys do it : http://www.enlighter.com/ but I'm not sure
if its possible to do this using JS only or if it
needs a browser
extension.
Thanks!
--Dave.
_______________________________________________
Rails-spinoffs mailing list
Rails-spinoffs@xxxxxxxxxxxxxxxxxxxxx
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
Important notice: This message is
intended for the individual(s) and entity(s) addressed. The information
contained in this transmission and any attached, may be confidential and may
also be the subject of legal privilege, public interest immunity or legal
professional privilege. Any review, retransmission, dissemination or other
use of, taking of any action in reliance upon this information by person or
entities other than the recipient is prohibited and requires authorization
from the sender. If you are not the addressee indicated in this message (or
responsible for delivery of the message to such person) you may not copy or
deliver this message to anyone. In such cases you should destroy this
message and kindly notify the sender by reply email.
WARNING: Although Infocomp has
taken reasonable precautions so that no viruses are present in this
e-mail, the company cannot accept responsibility for any loss or damage
arising from the use of e-mail attachments.
_______________________________________________
Rails-spinoffs mailing list