onpaste fired oncontextmenu

Somebody pointed out to me a rather troubling issue. Right-clicking on a page to bring up the context menu fires the onbeforepaste event. What if you want to copy text and not paste? The event shouldn't fire. The solution is not to use the default context menu. Create your own context menu to get around the issue.

Published August 29, 2003 · Updated September 17, 2005
Categorized as MSHTML and DEC
Short URL: https://snook.ca/s/14

Want to learn about scaling CSS for large projects?

I'm available for full and half-day workshops on scalable CSS architecture. I can provide on-site training for your team. Interested?
Get in touch.