1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to select all and copy text from iframe?

Discussion in 'HTML & Website Design' started by Boofer, May 20, 2008.

  1. #1
    I have text in the iframe and I was wondering how I can have users simply click anywhere in the iframe then automatically select all the text in the iframe and have it automatically copied so all they have to do is paste...

    Here is the code I have so far.


    SEMrush
     
    Boofer, May 20, 2008 IP
    SEMrush
  2. Boofer

    Boofer Peon

    Messages:
    6
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    bump for an answer
     
    Boofer, May 22, 2008 IP
  3. eruct

    eruct Well-Known Member

    Messages:
    1,189
    Likes Received:
    49
    Best Answers:
    0
    Trophy Points:
    108
    #3
    I can't think of a way to do exactly what you need, but if you could provide some more details as to why you want the user to do this and where they will be pasting it too there might be another solution to your problem...
     
    eruct, May 22, 2008 IP
  4. clark71822

    clark71822 Peon

    Messages:
    213
    Likes Received:
    3
    Best Answers:
    0
    Trophy Points:
    0
    #4
    clark71822, May 23, 2008 IP
  5. steelfrog

    steelfrog Peon

    Messages:
    537
    Likes Received:
    24
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Unfortunately, you will be hard-pressed to try and find a script that will work on all browsers since they all handle it differently. The JavaScript example mentioned above should do the work for Windows XP users on IE. I believe it does not work on Vista if memory serves, but I might be wrong on that one.
     
    steelfrog, May 23, 2008 IP