4

I have an iframe inside my product. I need to copy text from Google doc loaded on the iframe automatically on selecting a chunk of text.

Currently, I select a chunk of text and then right-click where I get a "copy" button as shown below.

Instead, as soon as I select a chunk of text, I want the text to be copied instead of taking one extra step to do right-click and select the copy option.

How to achieve this on an iframe. enter image description here

<ifram src="https://docs.google.com/document/d/e/2PACX-1vR2QgPd5m7tOqzk6C3PPtgl8dTlDArfKbWH2VQJdLt2SykaexgT_Mq-l6WrpnQe7PbhQ6iBMjoSojBI/pub" ref={iframeRef} />

Arsene Wenger
  • 587
  • 4
  • 21
  • 1
    I believe this would be seen as being [cross-site scripting](https://en.wikipedia.org/wiki/Cross-site_scripting). – Paul Feb 26 '23 at 09:34
  • Does this answer your question? [how to resolve iframe cross domain issue](https://stackoverflow.com/questions/40866219/how-to-resolve-iframe-cross-domain-issue) – Paul Feb 26 '23 at 09:37

0 Answers0