【问题标题】:In laravel using ajax call and get the document.execCommand("copy") but its not working在 laravel 中使用 ajax 调用并获取 document.execCommand("copy") 但它不起作用
【发布时间】:2019-09-19 08:30:10
【问题描述】:
$.ajax({
    type:'GET',
    url:apprul,
    success:function(request){
        var copy = $('.class');
        Clipboard(copy);
     },
     error: function (request, error)
     {
        alert('Your Login session is expiry please log in and try again');
        window.location.href = apprul;
      }
});

【问题讨论】:

  • 对 document.execCommand("copy") 的剪贴板(复制)函数调用。

标签: ajax laravel


【解决方案1】:
$.ajax({
   type:'GET',
   url:apprul,
   async: false, 
   success:function(request){
     var copy = $('.class');
     Clipboard(copy);
   },
   error: function (request, error)
   {
     alert('Your Login session is expiry please log in and try again');
     window.location.href = apprul;
    }
  });

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2021-02-08
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多