Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/277.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript blueimp Jquery文件上载-IE<;10_Javascript_Php_Jquery_File Upload_Jquery File Upload - Fatal编程技术网

Javascript blueimp Jquery文件上载-IE<;10

Javascript blueimp Jquery文件上载-IE<;10,javascript,php,jquery,file-upload,jquery-file-upload,Javascript,Php,Jquery,File Upload,Jquery File Upload,这个插件在每个borwser中都运行良好,但IE

这个插件在每个borwser中都运行良好,但IE<10。我正在尝试将Fileupload绑定到表单中的每个操作(文本更改、文件更改、按钮按下)。在表单中,我有文本区(wysiwyg)、文件输入和发送按钮。它应该随文件发送文本,但它只发送文本。这是我的代码:

     $(function() {

           try{

         var messageDiv;
         if($('#account-mail-send').length){
             messageDiv = '#account-mail-send';
         } else if($('#account-mail-received').length){
             messageDiv = '#account-mail-received';
         }

        $("#message_received #form-action").submit(function(event) {
            event.preventDefault();
        });



        $('#send_form_messages #button-0').click(function(){
            if ($('#contenteditable-content').val() === '') {
               $('#message').removeClass();
               $('#message').addClass('message_ajax_negative');
               $('#message').html(empty_message_error);
            } else {
                $('#message').removeClass();
                $('#message').addClass('hide');
            }
        });

        'use strict';
        // Change this to the location of your server-side upload handler:
        var url = 'index.php?action=user_panel_ajax&mode=wyslij_wiadomosc_odebrane&id=' + $('#id').val();


        $('#attach').fileupload({
            url: url,
            dataType: 'html',
            replaceFileInput: false,
            maxNumberOfFiles: 1,
            cache: false,
            beforeSend: function(event, files, index, xhr, handler, callBack) {

                $(messageDiv).css('opacity', 0.2);
                $(messageDiv+'-loader').css({
                    height: $('#account-mail-received').css('height'),
                    width: $('#account-mail-received').css('width'),
                    display: 'block'
                });
                $('#button-0').attr('disabled', true);
                $('#attach').attr('disabled', true);

                console.log(files);
            },
            done: function(e, data) {
                $('#button-0').attr('disabled', false);
                $('#attach').attr('disabled', false);
                $(messageDiv).css('opacity', 1);
                $(messageDiv+'-loader').css({
                    display: 'none'
                });
                $(messageDiv).html(data.result);
                $('#attach').val('');
                $('#list').html('');

                $('#attach').fileupload('add', {
                    fileInput: $(this)
                });
                jqueryEditable[0].wysiwyg('focus');
                jqueryEditable[0].wysiwyg('clear');

                $('#count-chars-0').html($('#contenteditable-content').attr('maxlength'));

            },
            fail: function(e, data) {
            },
            add: function(e, data) {
                $("#button-0").off('click').one('click', function() {
                    data.submit();
                });
            }
        });

        $('#message_received #contenteditable-content').change(function() {
            if ($('#attach').val() === '') {
                $('#attach').fileupload('add', {
                    fileInput: $(this)
                });
            }
        });

}catch(e){

console.log(e);

}

    });

您正在进行跨域上传吗?如果是的话,也许可以帮助你。你能解决这个问题吗?我也面临同样的问题