Copying content in readonly form elements does not work
-
Hello
When I try to copy the content from an input or textarea field with the readonly attribute, the content is not copied and the clipboard remains empty. In the settings of wp-Typography I have enabled the option “Remove conditional hyphens when copying to the clipboard” (machine translation). The script clean-clipboard.min.js seems to be responsible for this. In my case
sel.getRangeAt( 0 ).cloneContents()
returns an empty result. If I use the functionsel.toString()
to read the marked content instead, it works fine. Is there a special reason why you use getRangeAt and cloneContents to get the marked content or could you use the toString function instead?Thanks a lot!
The page I need help with: [log in to see the link]
- The topic ‘Copying content in readonly form elements does not work’ is closed to new replies.