clipBorad with zClip doesnt work in some browsers

290 views Asked by At

I 'm trying to use Clipboard Copy for one page written in asp.net I use zClip for browsers except IE , in some browsers(chrome most of the times), my button which do Clipboard Copy doesnt work, when I trace code with F12 in Chrome, this Error apears:

GET http://www.steamdev.com/zclip/js/ZeroClipboard.swf net::ERR_NAME_NOT_RESOLVED  

and for one other resource, this Error occurred

Failed to load resource: the server responded with a status of 404 (Not Found) 

why some browsers cant Load these Files ???

thanks for Any help or suggestion . :)

1

There are 1 answers

1
Mazzu On

It might be occurring due to browser and Flash security restrictions, the clipboard injection can ONLY occur when the user clicks on the invisible Flash movie. A simulated click event from JavaScript will not suffice as this would enable clipboard poisoning.

It has been mentioned as limitation of zclip plugin in its github repo. Please refer to github link for more details

And for clipboard poisoning please refer to this link

Also below are some points regarding zclip:

“The ZeroClipboard library provides an easy way to copy text to the clipboard using an invisible Adobe Flash movie and a JavaScript interface”

Advantages:

  1. Stylized the button
  2. Easy to use and configure
  3. Work well on Chrome, Firefox

Disadvantages:

  1. No flash, no action
  2. This clipboard injection can ONLY occur when the user clicks on the invisible Flash