SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    webality...dunno what it means bcp_2005's Avatar
    Join Date
    Jun 2002
    Location
    Huntsville Alabama
    Posts
    394
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Copy Selected Data

    Ok I'm trying to make a script where you can select something on the page, press a copy image on the page, and the script adds the data to the clipboard. I know that you can add data to the clipboard like this:

    window.clipboardData.setData("Text","Data to copy");

    But how can I find out what the user has selected? I know there's got to be some way to do it..but I can't figure out how.
    [ metabahn ] : changing the course of the web.

  2. #2
    SitePoint Evangelist Mr. Brownstone's Avatar
    Join Date
    May 2002
    Location
    Relative
    Posts
    452
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This recent SP article has the code you need.
    Of course, that's just my opinion. I could be wrong.

  3. #3
    webality...dunno what it means bcp_2005's Avatar
    Join Date
    Jun 2002
    Location
    Huntsville Alabama
    Posts
    394
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks! That's similar to what I need. I think it will at least get me off in the right direction!
    [ metabahn ] : changing the course of the web.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •