Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
435
Cut, copy paste not working in Firefox, Chrome and Safari
posted

I am using IG 20121.1005 and I have created rightclick menu in my editor for cut. copy and paste. The problem is that these functionalities are working only in IE. In firefox, the error message saying that "Browser does not support this feature" is displayed. In chrome and safari nothing happens if you copy and paste the text in editor.

 

 The sample of code is as follows:

<RightClickMenu ClientIDMode="Predictable">

<ighedit:HtmlBoxMenuItem runat="server" Act="Cut" ClientIDMode="Predictable" Height="10">
<Dialog ClientIDMode="Predictable" />
</ighedit:HtmlBoxMenuItem>

<ighedit:HtmlBoxMenuItem runat="server" Act="Copy" ClientIDMode="Predictable" Height="10">
<Dialog ClientIDMode="Predictable" />
</ighedit:HtmlBoxMenuItem>

<ighedit:HtmlBoxMenuItem runat="server" Act="Paste" ClientIDMode="Predictable" Height="10">            
<Dialog ClientIDMode="Predictable" />
</ighedit:HtmlBoxMenuItem>

<ighedit:HtmlBoxMenuItem runat="server" Act="PasteHtml" ClientIDMode="Predictable" Height="10">
<Dialog ClientIDMode="Predictable" />
</ighedit:HtmlBoxMenuItem>

 </RightClickMenu>

 

Regards

  • 24497
    posted

    Hi pkgal79,

    The clipboard operations from javascript, using document.execCommand(action), are not supported by most browsers except IE. Those browsers have strict security rules and WebHtmlEditor is not able defeat them.
    In theory Firefox might support that feature, but only if end user will explicitly configure its Firefox to disable security. Before clipboard action, the WebHtmlEditor tries to execute following statement:
    netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");

    If it fails, then alert is displayed.