When copying text from webpage, Hidden text may be copied too
This article provides information about hidden text that can be copied from a webpage and provides solutions to prevent this behavior.
Original product version: Internet Explorer 9 and later versions
Original KB number: 2974910
When you copy text from a webpage in Internet Explorer, hidden text may be copied as well, and will become visible when pasting that text into another application.
When you select the surrounding container of the hidden text, the hidden text is selected also.
This issue has been resolved when using Standards Mode from Internet Explorer 9 and later versions. To enable Standards Mode, see How to Enable Standards Support.
The following snippet of a webpage demonstrates the issue when you select both visible lines and then use copy + paste into a text editor:
<html> <body> This is a visible text. <div style="visibility:hidden">This text is hidden</div> This is a visible text. </body> <html>