我在我的网站上使用blueimp。blueimp包含在我的页面(索引)的末尾。php)喜欢:

 <?php include "index.html"; ?>

在我的php页面中,我还使用了一个jquery适配器,它通过以下方式发送来自同一页面的一些变量和来自blueimp uploader的两个变量:

   function save()
     {  
    var variable1= document.getElementById('field1').value;
        var variable2= CKEDITOR.instances.field2.getData();
    variable2=encodeURIComponent(variable2);
    var variable3= document.getElementById('field3').value;
        var variables="variable1="+variable1+ "&variable2="+variable2+                                 
                      "&variable3="+variable3;


           jQuery('#mydiv').showLoading();
           $.ajax({
                        type: "POST",
                        url: "some.php",
                        data: variables,
                        error: function(){
                           alert('Error while loading!');
                         },
                       success: function(data){
              jQuery('#mydiv').hideLoading();
                          $('#mydiv').html(data);
                      }
                });
    }

每当我调用此函数时,变量都不会发送给某些变量。php的。但是,如果我删除

       <?php include "index.html"; ?> 

从索引。php页面,函数save开始工作。我猜从包含的blueimp页面,这是索引的东西。html,阻止jquery适配器正常工作。

在这个问题上有什么线索吗?

先谢谢你。

有帮助吗?

解决方案

这听起来像你有两个库之间的一些冲突。jQuery有 选项调用 noConflict() 为了让你有点'暂停'jQuery,并允许其他库工作,然后'恢复'正常的jQuery功能。

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top